aboutsummaryrefslogtreecommitdiffstats
path: root/sink.c
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2005-07-03 18:21:04 +0000
committerMatthias Andree <matthias.andree@gmx.de>2005-07-03 18:21:04 +0000
commit2167dd645e64107eee8af5072a02953f9eb0ffd5 (patch)
tree2617e7ed33e8ad1dc84af107af7d259e958ba0f6 /sink.c
parent0d89042e41405763ae734174e55aa0fd2c8eeaec (diff)
downloadfetchmail-2167dd645e64107eee8af5072a02953f9eb0ffd5.tar.gz
fetchmail-2167dd645e64107eee8af5072a02953f9eb0ffd5.tar.bz2
fetchmail-2167dd645e64107eee8af5072a02953f9eb0ffd5.zip
Nalin Dahyabhai's fix for sink.c/transact.c to reserve sufficient
space for \r\n trailers in snprintf calls. Sent by Miloslav Trmac, possibly fixing Red Hat bug #114470. svn path=/trunk/; revision=4071
Diffstat (limited to 'sink.c')
-rw-r--r--sink.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sink.c b/sink.c
index 68a1739b..59c4fab7 100644
--- a/sink.c
+++ b/sink.c
@@ -1540,7 +1540,7 @@ va_dcl
#else
va_start(ap);
#endif
- vsnprintf(buf, sizeof(buf), fmt, ap);
+ vsnprintf(buf, sizeof(buf) - 2, fmt, ap);
va_end(ap);
snprintf(buf+strlen(buf), sizeof(buf)-strlen(buf), "\r\n");