Skip to content
Snippets Groups Projects
Commit 203f66d0 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

James Bursa's fix to prevent failf() to write outside its buffer boundary

parent 54c6f2c7
No related branches found
No related tags found
No related merge requests found
......@@ -154,7 +154,7 @@ void Curl_failf(struct SessionHandle *data, const char *fmt, ...)
if(data->set.verbose) {
int len = strlen(data->set.errorbuffer);
bool doneit=FALSE;
if(len < CURL_ERROR_SIZE) {
if(len < CURL_ERROR_SIZE - 1) {
doneit = TRUE;
data->set.errorbuffer[len] = '\n';
data->set.errorbuffer[++len] = '\0';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment