X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Flibpspp%2Fstr.c;h=6b207ee288f66f4c941ecf8940153ea1e83bd481;hb=cf4da7ffcb1c9f1016c4fa013deb8ce40c431e19;hp=530d1cecded30897c41c1d1e1f0787a50e0aa99c;hpb=c579d031aa989de4af85ff94bbbbb141b56ecbf5;p=pspp-builds.git diff --git a/src/libpspp/str.c b/src/libpspp/str.c index 530d1cec..6b207ee2 100644 --- a/src/libpspp/str.c +++ b/src/libpspp/str.c @@ -26,53 +26,6 @@ #include "alloc.h" #include "message.h" -/* sprintf() wrapper functions for convenience. */ - -#if !__GNUC__ -char * -spprintf (char *buf, const char *format,...) -{ -#if HAVE_GOOD_SPRINTF - int count; -#endif - va_list args; - - va_start (args, format); -#if HAVE_GOOD_SPRINTF - count = -#endif - vsprintf (buf, format, args); - va_end (args); - -#if HAVE_GOOD_SPRINTF - return &buf[count]; -#else - return strchr (buf, 0); -#endif -} -#endif /* !__GNUC__ */ - -#if !__GNUC__ && !HAVE_GOOD_SPRINTF -int -nsprintf (char *buf, const char *format,...) -{ - va_list args; - - va_start (args, format); - vsprintf (buf, format, args); - va_end (args); - - return strlen (buf); -} - -int -nvsprintf (char *buf, const char *format, va_list args) -{ - vsprintf (buf, format, args); - return strlen (buf); -} -#endif /* Not GNU C and not good sprintf(). */ - /* Reverses the order of NBYTES bytes at address P, thus converting between little- and big-endian byte orders. */ void