Replaced all uses of sprintf() with the safer snprintf(). It is just a
precaution to prevent mistakes to lead to buffer overflows.
This commit is contained in:
@@ -846,7 +846,7 @@ static CURLcode AddFormDataf(struct FormData **formp,
|
||||
char s[4096];
|
||||
va_list ap;
|
||||
va_start(ap, fmt);
|
||||
vsprintf(s, fmt, ap);
|
||||
vsnprintf(s, sizeof(s), fmt, ap);
|
||||
va_end(ap);
|
||||
|
||||
return AddFormData(formp, FORM_DATA, s, 0, size);
|
||||
|
||||
Reference in New Issue
Block a user