diff options
author | Eric Wong <e@80x24.org> | 2015-08-18 01:11:04 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2015-08-18 01:11:53 +0000 |
commit | 6a19d29cb98823ee3794d295e122ee265ab3016a (patch) | |
tree | f73aef5f9d98ab9205c7b76735415594058381c4 /t | |
parent | 7310cc79cea5ba64b1cc7c97169d811d8a4653a0 (diff) | |
download | public-inbox-6a19d29cb98823ee3794d295e122ee265ab3016a.tar.gz |
Some mail software incorrectly creates circular references and causes us to create ghosts before the actual mail doc is created.
Diffstat (limited to 't')
-rw-r--r-- | t/search.t | 19 |
1 files changed, 19 insertions, 0 deletions
@@ -243,6 +243,25 @@ sub filter_mids { "quoted result returned if nothing else"); } +# circular references +{ + my $doc_id = $rw->add_message(Email::MIME->create( + header_str => [ + Date => 'Sat, 02 Oct 2010 00:00:01 +0000', + Subject => 'Circle', + 'Message-ID' => '<circle@a>', + 'References' => '<circle@a>', + 'In-Reply-To' => '<circle@a>', + From => 'Circle <circle@example.com>', + To => 'list@example.com', + ], + body => "LOOP!\n")); + ok($doc_id > 0, "doc_id defined with circular reference"); + my $smsg = $rw->lookup_message('circle@a'); + $smsg->ensure_metadata; + is($smsg->{references}, undef, "no references created"); +} + done_testing(); 1; |