By default MIME:Parser::Filer uses the attachement's recommended filename to save it to disk. However that name is tainted which causes Perl to throw an exception. Since we don't actually care about the filename (all mailing list patches are called 'patch.diff'), simply tell the filer to generate its own filename.
Signed-off-by: Francois Gouget fgouget@codeweavers.com ---
The only reason this has not impacted the official TestBot so far is that the mailing list patches go through the patches website which (mis)handles the attachments (bug 48795) and then WinePatchesWebSubmit.pl, instead of going straight in through WinePatchesMLSubmit.pl.
testbot/bin/Engine.pl | 1 + 1 file changed, 1 insertion(+)
diff --git a/testbot/bin/Engine.pl b/testbot/bin/Engine.pl index 48bb797cc0..db9d82d300 100755 --- a/testbot/bin/Engine.pl +++ b/testbot/bin/Engine.pl @@ -428,6 +428,7 @@ sub HandleWinePatchMLSubmission() # Process the email my $Parser = new MIME::Parser; $Parser->output_dir($WorkDir); + $Parser->filer->ignore_filename(1); my $Entity = $Parser->parse_open($FullMessageFileName); my $ErrMessage = CreatePatches()->NewPatch($Entity); if (defined $ErrMessage)