Fix checking for missing boundary line. Still more to improve for multipart messages.
This commit is contained in:
parent
9e6a344453
commit
797aa147a6
|
@ -49,12 +49,12 @@ function message_parse($rawmessage)
|
||||||
// We have multible bodies, so we split the message into its parts
|
// We have multible bodies, so we split the message into its parts
|
||||||
$boundary = "--" . $message->header->content_type_boundary;
|
$boundary = "--" . $message->header->content_type_boundary;
|
||||||
// lets find the first part
|
// lets find the first part
|
||||||
|
|
||||||
while ($rawmessage[$i] != $boundary) {
|
while ($rawmessage[$i] != $boundary) {
|
||||||
|
$i ++;
|
||||||
|
// Missing boundary line?
|
||||||
if(!$rawmessage[$i]) {
|
if(!$rawmessage[$i]) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
$i ++;
|
|
||||||
}
|
}
|
||||||
$i ++;
|
$i ++;
|
||||||
$part = array();
|
$part = array();
|
||||||
|
@ -837,6 +837,12 @@ function message_show($group, $id, $attachment = 0, $article_data = false, $maxl
|
||||||
return "no-archive";
|
return "no-archive";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(isset($head->content_type[0])) {
|
||||||
|
if(!strpos($head->content_type[0], "/")) {
|
||||||
|
echo '<hr><p class=np_ob_posted_date>(message #' . $head->number . ' not displayed - malformed header)</p><hr>';
|
||||||
|
return "blocked";
|
||||||
|
}
|
||||||
|
}
|
||||||
if (($head->content_type[$attachment] == "text/plain") && ($attachment == 0)) {
|
if (($head->content_type[$attachment] == "text/plain") && ($attachment == 0)) {
|
||||||
show_header($head, $group, $local_poster);
|
show_header($head, $group, $local_poster);
|
||||||
// X-Face
|
// X-Face
|
||||||
|
|
Loading…
Reference in New Issue