summaryrefslogtreecommitdiffstats
path: root/libexec
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2019-07-03 03:24:01 +0000
committerderaadt <deraadt@openbsd.org>2019-07-03 03:24:01 +0000
commit515e489c3d599b9cfcdf9cf6842ac49f92e154d6 (patch)
tree9ce211473951e1baf5c99e08c2c35012292670f1 /libexec
parentsync (diff)
downloadwireguard-openbsd-515e489c3d599b9cfcdf9cf6842ac49f92e154d6.tar.xz
wireguard-openbsd-515e489c3d599b9cfcdf9cf6842ac49f92e154d6.zip
snprintf/vsnprintf return < 0 on error, rather than -1.
Diffstat (limited to 'libexec')
-rw-r--r--libexec/ftpd/ftpd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libexec/ftpd/ftpd.c b/libexec/ftpd/ftpd.c
index eff1cd1099a..243881be9c3 100644
--- a/libexec/ftpd/ftpd.c
+++ b/libexec/ftpd/ftpd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ftpd.c,v 1.227 2019/06/28 13:32:53 deraadt Exp $ */
+/* $OpenBSD: ftpd.c,v 1.228 2019/07/03 03:24:04 deraadt Exp $ */
/* $NetBSD: ftpd.c,v 1.15 1995/06/03 22:46:47 mycroft Exp $ */
/*
@@ -2771,7 +2771,7 @@ logxfer(char *name, off_t size, time_t start)
((guest) ? "*" : pw->pw_name), dhostname);
free(vpw);
- if (len == -1 || len >= sizeof(buf)) {
+ if (len < 0 || len >= sizeof(buf)) {
if ((len = strlen(buf)) == 0)
return; /* should not happen */
buf[len - 1] = '\n';