comparison src/lib-mail/istream-header-filter.c @ 21610:50c907a9d31b

lib-mail: Fix matched-parameter in HEADER_FILTER_ADD_MISSING_EOH callback The matched-parameter in the regular EOH callback is the reverse of what it's in v2.3 tree. So preserve it here.
author Timo Sirainen <timo.sirainen@dovecot.fi>
date Mon, 20 Feb 2017 00:26:28 +0200
parents bf07e3be3f6a
children e3ebc1be3d49
comparison
equal deleted inserted replaced
21609:3c0773815e3e 21610:50c907a9d31b
304 mstream->istream.istream.eof = 304 mstream->istream.istream.eof =
305 mstream->istream.parent->eof; 305 mstream->istream.parent->eof;
306 return -1; 306 return -1;
307 } 307 }
308 if (!mstream->seen_eoh && mstream->add_missing_eoh) { 308 if (!mstream->seen_eoh && mstream->add_missing_eoh) {
309 bool matched = FALSE; 309 bool matched = TRUE;
310 310
311 mstream->seen_eoh = TRUE; 311 mstream->seen_eoh = TRUE;
312 312
313 if (!mstream->last_added_newline) 313 if (!mstream->last_added_newline)
314 add_eol(mstream, mstream->last_orig_crlf); 314 add_eol(mstream, mstream->last_orig_crlf);
324 mstream->callback(mstream, &fake_eoh_hdr, 324 mstream->callback(mstream, &fake_eoh_hdr,
325 &matched, mstream->context); 325 &matched, mstream->context);
326 mstream->callbacks_called = TRUE; 326 mstream->callbacks_called = TRUE;
327 } 327 }
328 328
329 if (matched) { 329 if (!matched) {
330 mstream->seen_eoh = FALSE; 330 mstream->seen_eoh = FALSE;
331 } else { 331 } else {
332 add_eol(mstream, mstream->last_orig_crlf); 332 add_eol(mstream, mstream->last_orig_crlf);
333 } 333 }
334 } 334 }