diff options
author | Daniel Stenberg <daniel@haxx.se> | 2003-10-27 06:35:47 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2003-10-27 06:35:47 +0000 |
commit | 203f66d0cb9f75f5dadcaec2cf4be47db1fbbc49 (patch) | |
tree | d0ca955acbfb1b6d286ed7efa9e4d06075173961 /lib/sendf.c | |
parent | 54c6f2c7c05d33859789bc3a1754805ee31c6edb (diff) | |
download | curl-203f66d0cb9f75f5dadcaec2cf4be47db1fbbc49.tar.gz |
James Bursa's fix to prevent failf() to write outside its buffer boundary
Diffstat (limited to 'lib/sendf.c')
-rw-r--r-- | lib/sendf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sendf.c b/lib/sendf.c index 41f309236..2459161d1 100644 --- a/lib/sendf.c +++ b/lib/sendf.c @@ -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'; |