Commit 2690700
committed
mod_mimeparse: Return NULL in bbs_mime_message_parse if mk_mime fails.
Do not return an "empty" mime container if mk_mime fails, since this
will lead to a NULL dereference later inside
bbs_mime_make_bodystructure. This could occur if analyzing invalid
maildir files, such as swap files, inside the maildir "cur" directory.
While resulting behavior will not be correct since swap files should
not be present (or should be ignored if present), this should at least
avoid a crash.
LBBS-146 #close1 parent d360dff commit 2690700
1 file changed
Lines changed: 13 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
382 | 382 | | |
383 | 383 | | |
384 | 384 | | |
385 | | - | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
386 | 396 | | |
| 397 | + | |
387 | 398 | | |
388 | 399 | | |
389 | | - | |
| 400 | + | |
390 | 401 | | |
391 | 402 | | |
392 | 403 | | |
| |||
0 commit comments