summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2001-07-27 17:26:16 +0000
committerderaadt <deraadt@openbsd.org>2001-07-27 17:26:16 +0000
commit36088f4e9092da43b1ff6abadde655617b29f22c (patch)
treed059bb5c97efe445ac8709aa9f19d7a6ac00e68e
parentUse snprintf to avoid potential overflows; zen-parse@gmx.net (diff)
downloadwireguard-openbsd-36088f4e9092da43b1ff6abadde655617b29f22c.tar.xz
wireguard-openbsd-36088f4e9092da43b1ff6abadde655617b29f22c.zip
shorten lines
-rw-r--r--usr.bin/ssh/scp.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/usr.bin/ssh/scp.c b/usr.bin/ssh/scp.c
index abc4775f15f..0051e20f0e3 100644
--- a/usr.bin/ssh/scp.c
+++ b/usr.bin/ssh/scp.c
@@ -75,7 +75,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: scp.c,v 1.77 2001/07/18 16:45:52 mouring Exp $");
+RCSID("$OpenBSD: scp.c,v 1.78 2001/07/27 17:26:16 deraadt Exp $");
#include "xmalloc.h"
#include "atomicio.h"
@@ -129,8 +129,10 @@ do_cmd(char *host, char *remuser, char *cmd, int *fdin, int *fdout, int argc)
int pin[2], pout[2], reserved[2];
if (verbose_mode)
- fprintf(stderr, "Executing: program %s host %s, user %s, command %s\n",
- ssh_program, host, remuser ? remuser : "(unspecified)", cmd);
+ fprintf(stderr,
+ "Executing: program %s host %s, user %s, command %s\n",
+ ssh_program, host,
+ remuser ? remuser : "(unspecified)", cmd);
/*
* Reserve two descriptors so that the real pipes won't get
@@ -803,7 +805,8 @@ bad: run_err("%s: %s", np, strerror(errno));
count += amt;
do {
j = read(remin, cp, amt);
- if (j == -1 && (errno == EINTR || errno == EAGAIN)) {
+ if (j == -1 && (errno == EINTR ||
+ errno == EAGAIN)) {
continue;
} else if (j <= 0) {
run_err("%s", j ? strerror(errno) :
@@ -1092,8 +1095,10 @@ progressmeter(int flag)
i = barlength * ratio / 100;
snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf),
"|%.*s%*s|", i,
- "*****************************************************************************"
- "*****************************************************************************",
+ "***************************************"
+ "***************************************"
+ "***************************************"
+ "***************************************",
barlength - i, "");
}
i = 0;