diff options
author | Eric Wong <e@80x24.org> | 2020-12-10 23:04:50 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2020-12-11 03:38:08 +0000 |
commit | ac4f951e03eaf635c8dd20a6f42bfc71b0011412 (patch) | |
tree | b70507449df7f54afeeb4e9f486958a7946398d4 /lib/PublicInbox/ExtMsg.pm | |
parent | aaf5e53c44a2123f80133e1722cc864f17010808 (diff) | |
download | public-inbox-ac4f951e03eaf635c8dd20a6f42bfc71b0011412.tar.gz |
If a message can't be found in ->ALL, we shouldn't attempt to enter code paths which iterate normal inboxes or attempt to access non-existent fields (e.g. {name}, {newsgroup}, {inboxdir}) in the ExtSearch object.
Diffstat (limited to 'lib/PublicInbox/ExtMsg.pm')
-rw-r--r-- | lib/PublicInbox/ExtMsg.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/PublicInbox/ExtMsg.pm b/lib/PublicInbox/ExtMsg.pm index 8da96df6..6a173f67 100644 --- a/lib/PublicInbox/ExtMsg.pm +++ b/lib/PublicInbox/ExtMsg.pm @@ -107,7 +107,8 @@ sub ext_msg_ALL ($) { my ($ctx) = @_; my $ALL = $ctx->{www}->{pi_cfg}->ALL or return; my $by_eidx_key = $ctx->{www}->{pi_cfg}->{-by_eidx_key}; - my $cur_key = $ctx->{ibx}->eidx_key; + my $cur_key = eval { $ctx->{ibx}->eidx_key } // + return partial_response($ctx); # $cur->{ibx} == $ALL my %seen = ($cur_key => 1); my ($id, $prev); while (my $x = $ALL->over->next_by_mid($ctx->{mid}, \$id, \$prev)) { |