aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2003-10-27 06:35:47 +0000
committerDaniel Stenberg <daniel@haxx.se>2003-10-27 06:35:47 +0000
commit203f66d0cb9f75f5dadcaec2cf4be47db1fbbc49 (patch)
treed0ca955acbfb1b6d286ed7efa9e4d06075173961 /lib
parent54c6f2c7c05d33859789bc3a1754805ee31c6edb (diff)
James Bursa's fix to prevent failf() to write outside its buffer boundary
Diffstat (limited to 'lib')
-rw-r--r--lib/sendf.c2
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';