summaryrefslogtreecommitdiffstats
path: root/contrib/sendmail/libsm/vfprintf.c
diff options
context:
space:
mode:
authorgshapiro <gshapiro@FreeBSD.org>2006-03-22 16:40:03 +0000
committergshapiro <gshapiro@FreeBSD.org>2006-03-22 16:40:03 +0000
commitef9770707c0f88e94a0c4a409f8fb74cea250716 (patch)
treef3bd1c133ce6e698fd2ff3c0280c7103bfac7af3 /contrib/sendmail/libsm/vfprintf.c
parent3f99651e549f30e601bcde5ce7907ee58c365442 (diff)
downloadFreeBSD-src-ef9770707c0f88e94a0c4a409f8fb74cea250716.zip
FreeBSD-src-ef9770707c0f88e94a0c4a409f8fb74cea250716.tar.gz
Import sendmail 8.13.6
Security: FreeBSD-SA-06:13.sendmail
Diffstat (limited to 'contrib/sendmail/libsm/vfprintf.c')
-rw-r--r--contrib/sendmail/libsm/vfprintf.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/contrib/sendmail/libsm/vfprintf.c b/contrib/sendmail/libsm/vfprintf.c
index e77c335..c4ca9bb 100644
--- a/contrib/sendmail/libsm/vfprintf.c
+++ b/contrib/sendmail/libsm/vfprintf.c
@@ -13,7 +13,7 @@
*/
#include <sm/gen.h>
-SM_IDSTR(id, "@(#)$Id: vfprintf.c,v 1.53 2004/08/03 20:54:49 ca Exp $")
+SM_IDSTR(id, "@(#)$Id: vfprintf.c,v 1.54 2005/05/16 03:52:00 ca Exp $")
/*
** Overall:
@@ -535,9 +535,19 @@ reswitch: switch (ch)
if (prec > 120)
prec = 120;
if (prec >= 0)
+#if HASSNPRINTF
+ snprintf(out, sizeof(out), fmt, width,
+ prec, val);
+#else /* HASSNPRINTF */
sprintf(out, fmt, width, prec, val);
+#endif /* HASSNPRINTF */
else
+#if HASSNPRINTF
+ snprintf(out, sizeof(out), fmt, width,
+ val);
+#else /* HASSNPRINTF */
sprintf(out, fmt, width, val);
+#endif /* HASSNPRINTF */
len = strlen(out);
PRINT(out, len);
FLUSH();
OpenPOWER on IntegriCloud