* [PATCH] view: do not fail on empty In-Reply-To
@ 2016-08-05 1:03 7% Eric Wong
0 siblings, 0 replies; 1+ results
From: Eric Wong @ 2016-08-05 1:03 UTC (permalink / raw)
To: meta
Sometimes messages have an empty In-Reply-To header which throws
threaders off. This actually causes public-inbox-httpd to die,
which is probably bad and will be fixed elsewhere.
---
lib/PublicInbox/View.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/PublicInbox/View.pm b/lib/PublicInbox/View.pm
index e0d81f0..db0cdc0 100644
--- a/lib/PublicInbox/View.pm
+++ b/lib/PublicInbox/View.pm
@@ -94,7 +94,7 @@ sub in_reply_to {
my ($hdr) = @_;
my $irt = $hdr->header_raw('In-Reply-To');
- return mid_clean($irt) if (defined $irt);
+ return mid_clean($irt) if defined $irt && $irt ne '';
my $refs = $hdr->header_raw('References');
if ($refs && $refs =~ /<([^>]+)>\s*\z/s) {
--
EW
^ permalink raw reply related [relevance 7%]
Results 1-1 of 1 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2016-08-05 1:03 7% [PATCH] view: do not fail on empty In-Reply-To Eric Wong
Code repositories for project(s) associated with this public inbox
https://80x24.org/public-inbox.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).