Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
Please login to access the resource
openSUSE:Leap:42.3:Update
alpine
chappa-unixnullbug.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File chappa-unixnullbug.patch of Package alpine
--- imap/src/c-client/mail.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) Index: alpine-2.20/imap/src/c-client/mail.c =================================================================== --- alpine-2.20.orig/imap/src/c-client/mail.c +++ alpine-2.20/imap/src/c-client/mail.c @@ -3400,13 +3400,13 @@ unsigned long mail_filter (char *text,un long flags) { STRINGLIST *hdrs; - int notfound; + int notfound, fix = text[len - 1] == '\0'; unsigned long i; char c,*s,*e,*t,tmp[MAILTMPLEN]; char *src = text; char *dst = src; char *end = text + len; - text[len] = '\012'; /* guard against running off buffer */ + text[fix ? len - 1 : len] = '\012'; /* guard against running off buffer */ while (src < end) { /* process header */ /* slurp header line name */ for (s = src,e = s + MAILTMPLEN - 1,e = (e < end ? e : end),t = tmp; @@ -3447,6 +3447,10 @@ unsigned long mail_filter (char *text,un } } *dst = '\0'; /* tie off destination */ + if(fix){ + text[len] = '\012'; + text[len-1] = '\0'; + } return dst - text; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor