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:
Daniel Stenberg 2004-06-24 11:54:11 +00:00
parent 5e34f3dc01
commit feb2dd2835
13 changed files with 490 additions and 486 deletions

View file

@ -68,7 +68,7 @@ char *curl_escape(const char *string, int length)
ns = testing_ptr;
}
}
sprintf(&ns[strindex], "%%%02X", in);
snprintf(&ns[strindex], 4, "%%%02X", in);
strindex+=3;
}