diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2023-08-27 22:58:39 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2023-08-27 22:58:39 +0000 |
commit | 0cc7ccdefa6f1fd3f8e23254c34f956156136a39 (patch) | |
tree | 8b56862abcdbd7778974c8e96eeefe9fbb2bb09e /editor | |
parent | 6748da2ec290df7a6430dcdc222b5d7e00808d4e (diff) | |
download | netpbm-mirror-0cc7ccdefa6f1fd3f8e23254c34f956156136a39.tar.gz netpbm-mirror-0cc7ccdefa6f1fd3f8e23254c34f956156136a39.tar.xz netpbm-mirror-0cc7ccdefa6f1fd3f8e23254c34f956156136a39.zip |
cleanup
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@4619 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'editor')
-rw-r--r-- | editor/specialty/pnmindex.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/editor/specialty/pnmindex.c b/editor/specialty/pnmindex.c index 2b39e4ec..dcb183ef 100644 --- a/editor/specialty/pnmindex.c +++ b/editor/specialty/pnmindex.c @@ -15,12 +15,14 @@ ============================================================================*/ #define _DEFAULT_SOURCE /* New name for SVID & BSD source defines */ +#define _C99_SOURCE /* Make sure snprintf() is in stdio.h */ #define _XOPEN_SOURCE 500 /* Make sure strdup() is in string.h */ #define _BSD_SOURCE /* Make sure strdup is in string.h */ #include <assert.h> #include <unistd.h> #include <stdarg.h> +#include <stdio.h> #include <errno.h> #include <sys/stat.h> @@ -61,7 +63,7 @@ systemf(const char * const fmt, va_start(varargs, fmt); - pm_vsnprintf(NULL, 0, fmt, varargs, &dryRunLen); + dryRunLen = vsnprintf(NULL, 0, fmt, varargs); va_end(varargs); @@ -82,7 +84,7 @@ systemf(const char * const fmt, va_start(varargs, fmt); - pm_vsnprintf(shellCommand, allocSize, fmt, varargs, &realLen); + realLen = vsnprintf(shellCommand, allocSize, fmt, varargs); assert(realLen == dryRunLen); va_end(varargs); |