strncpy(this_recp, org_recp, sizeof this_recp);
int i;
- for (i=0; i<3; ++i) { // pass three times through the aliaser
+ for (i=0; i<3; ++i) { // pass three times through the aliaser
mailtype = expand_aliases(this_recp, aliases);
// If an alias expanded to multiple recipients, strip off those recipients and append them
*FieldEnd = pFieldEnd;
// convert non-space whitespace to spaces, and remove double blanks
- for (sField = *field = pField;
- sField < pFieldEnd;
- pField++, sField++)
- {
- if ((*sField=='\r') || (*sField=='\n'))
- {
+ for (sField = *field = pField; sField < pFieldEnd; pField++, sField++) {
+ if ((*sField=='\r') || (*sField=='\n')) {
int offset = 1;
while ( ( (*(sField + offset) == '\r') || (*(sField + offset) == '\n' )) && (sField + offset < pFieldEnd) ) {
offset ++;
pField++;
sField++;
- while ((sField < pFieldEnd) &&
- isspace(*sField))
+ while ((sField < pFieldEnd) && isspace(*sField))
sField++;
*pField = *sField;
}
processed = 1;
}
-
-
// Clean up and move on.
free(key); // Don't free 'value', it's actually the same buffer
return processed;
}
++pos;
-
}
// At this point we have a field. Are we interested in it?
alldone = 1;
}
StrBufAppendBufPlain(OtherHeaders, HKEY("\n"), 0);
- if (pos < totalend)
+ if (pos < totalend) {
StrBufAppendBufPlain(OtherHeaders, pos, totalend - pos, 0);
+ }
FreeStrBuf(rfc822);
CM_SetAsFieldSB(msg, eMessageText, &OtherHeaders);
}
-// Harvest any email addresses that someone might want to have in their
-// "collected addresses" book.
+// Harvest any email addresses that someone might want to have in their "collected addresses" book.
char *harvest_collected_addresses(struct CtdlMessage *msg) {
char *coll = NULL;
char addr[256];