diff --git a/cmText.c b/cmText.c index fd0fe35..d2c9d2c 100644 --- a/cmText.c +++ b/cmText.c @@ -208,7 +208,8 @@ cmChar_t* cmTsVPrintfP( cmChar_t* s, const cmChar_t* fmt, va_list vl ) va_list vl1; va_copy(vl1,vl); - unsigned n = vsnprintf(NULL,0,fmt,vl); + int n = vsnprintf(NULL,0,fmt,vl); + assert(n != -1); s = cmMemResize(cmChar_t,s,n+1);