Commit afa92975 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

snprintf portability fix (ITS#2128)

parent e8303cbe
...@@ -55,6 +55,9 @@ int ber_pvt_vsnprintf( char *str, size_t n, const char *fmt, va_list ap ) ...@@ -55,6 +55,9 @@ int ber_pvt_vsnprintf( char *str, size_t n, const char *fmt, va_list ap )
fclose( f ); fclose( f );
signal( SIGPIPE, sig ); signal( SIGPIPE, sig );
if ( res > 0 && res < n ) {
res = vsprintf( str, fmt, ap );
}
return res; return res;
} }
#endif #endif
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment