Fix snprintf related failures on IRIX.

This commit is contained in:
Kevin Bowling 2010-11-23 19:40:23 -07:00 committed by Nick Mathewson
parent 1cd45e5660
commit 32390732d7

View File

@ -1483,6 +1483,13 @@ evutil_vsnprintf(char *buf, size_t buflen, const char *format, va_list ap)
r = _vsnprintf(buf, buflen, format, ap);
if (r < 0)
r = _vscprintf(format, ap);
#elif defined(sgi)
/* Make sure we always use the correct vsnprintf on IRIX */
extern int _xpg5_vsnprintf(char * __restrict,
__SGI_LIBC_NAMESPACE_QUALIFIER size_t,
const char * __restrict, /* va_list */ char *);
r = _xpg5_vsnprintf(buf, buflen, format, ap);
#else
r = vsnprintf(buf, buflen, format, ap);
#endif