diff options
author | Bjoern A. Zeeb <bz@FreeBSD.org> | 2017-02-28 18:10:03 +0000 |
---|---|---|
committer | Bjoern A. Zeeb <bz@FreeBSD.org> | 2017-02-28 18:10:03 +0000 |
commit | 6d9160409317733fd7cf140d8f33fe408e69ee40 (patch) | |
tree | ca4ef9cec4e2f93843fa7edd3bef14961cc93bf4 /lib | |
parent | 6414b02d0c8de09a757d0fb44cb4ab8c7c32c468 (diff) | |
download | src-6d9160409317733fd7cf140d8f33fe408e69ee40.tar.gz src-6d9160409317733fd7cf140d8f33fe408e69ee40.zip |
Properly indent a default: label and avoid crashing when running
under -v but cannot connect due to trying to print an int as %s [1].
Reported by: andrew [1]
MFC after: 3 days
Notes
Notes:
svn path=/head/; revision=314396
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libfetch/common.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libfetch/common.c b/lib/libfetch/common.c index 8ec7d018aa3d..e153bb5926a0 100644 --- a/lib/libfetch/common.c +++ b/lib/libfetch/common.c @@ -153,7 +153,7 @@ fetch_syserr(void) case EHOSTDOWN: fetchLastErrCode = FETCH_DOWN; break; -default: + default: fetchLastErrCode = FETCH_UNKNOWN; } snprintf(fetchLastErrString, MAXERRSTRING, "%s", strerror(errno)); @@ -371,7 +371,7 @@ fetch_connect(const char *host, int port, int af, int verbose) } if (err != 0) { if (verbose) - fetch_info("failed to connect to %s:%s", host, port); + fetch_info("failed to connect to %s:%d", host, port); goto syserr; } |