From 01e94249b651dfe388b015d54911c35392ef1f0b Mon Sep 17 00:00:00 2001 From: DJ Delorie Date: Sat, 28 May 2005 19:49:24 +0000 Subject: merge from gcc --- include/libiberty.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include/libiberty.h') diff --git a/include/libiberty.h b/include/libiberty.h index 9af981c..75cbedc 100644 --- a/include/libiberty.h +++ b/include/libiberty.h @@ -531,6 +531,16 @@ extern int vasprintf (char **, const char *, va_list) ATTRIBUTE_PRINTF(2,0); #endif +#if defined(HAVE_DECL_SNPRINTF) && !HAVE_DECL_SNPRINTF +/* Like sprintf but prints at most N characters. */ +extern int snprintf (char *, size_t, const char *, ...) ATTRIBUTE_PRINTF_3; +#endif + +#if defined(HAVE_DECL_VSNPRINTF) && !HAVE_DECL_VSNPRINTF +/* Like vsprintf but prints at most N characters. */ +extern int vsnprintf (char *, size_t, const char *, va_list); +#endif + #define ARRAY_SIZE(a) (sizeof (a) / sizeof ((a)[0])) /* Drastically simplified alloca configurator. If we're using GCC, -- cgit v1.1