75 if (line.len == 1)
break;
76 if ((line.s[0] ==
' ') || (line.s[0] ==
'\t')) {
83 if (stralloc_starts(&line,
"Subject: success notice"))
85 if (stralloc_starts(&line,
"Subject: deferral notice"))
87 if (stralloc_starts(&line,
"Precedence: bulk"))
89 if (stralloc_starts(&line,
"Precedence: junk"))
92 if (stralloc_starts(&line,
"Subject: Message status - delivered"))
94 if (stralloc_starts(&line,
"Subject: Message status - opened"))
96 if (stralloc_starts(&line,
"Subject: Out of Office AutoReply:"))
99 if (stralloc_starts(&line,
"From: Mail Delivery Subsystem <MAILER-DAEMON@"))
101 if (stralloc_starts(&line,
"Subject: Warning: could not send message"))
103 if (stralloc_starts(&line,
"Subject: Returned mail: warning: cannot send message"))
105 if (stralloc_starts(&line,
"Auto-Submitted: auto-generated (warning"))
107 if (case_startb(line.s,line.len,
"Content-type: multipart/report"))
125 }
else if (case_startb(
dsnline.s + i,
dsnline.len - i,
"boundary=")) {
147 if ((line.len ==
boundary.len + 5) && (line.s[line.len - 1] ==
'-')
148 && (line.s[line.len - 2] ==
'-'))
152 if (case_startb(line.s,line.len,
"content-type:")) {
154 while ((line.s[i] ==
' ') || (line.s[i] ==
'\t'))
155 if (++i >= line.len)
break;
157 if (case_startb(line.s+i,line.len - i,
"message/delivery-status")) {
161 if (case_startb(line.s,line.len,
"action:")) {
163 while ((line.s[i] ==
' ') || (line.s[i] ==
'\t'))
164 if (++i >= line.len)
break;
166 if (case_startb(line.s + i,line.len - i,
"failed"))
188 if (stralloc_starts(&
line1,
"This is a MIME-encapsulated message"))
189 if (stralloc_starts(&
line3,
"--"))
const char * logmsg(const char *dir, unsigned long num, unsigned long listno, unsigned long subs, int done)