From: A. Shimono Date: Wed, 20 Jun 2012 22:17:33 +0000 (+0200) Subject: Bug 762785: Attachments are attached to the wrong comment when created by email_in.pl X-Git-Tag: bugzilla-4.3.2~40 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a4ef21ac8165538bf9cfe7adb7272fda4cece5d6;p=thirdparty%2Fbugzilla.git Bug 762785: Attachments are attached to the wrong comment when created by email_in.pl r/a=LpSolit --- diff --git a/email_in.pl b/email_in.pl index 3b684b0fcc..53b5ac2a88 100755 --- a/email_in.pl +++ b/email_in.pl @@ -233,7 +233,8 @@ sub process_bug { my $added_comment; if (trim($fields{'comment'})) { - $added_comment = $bug->comments->[-1]; + # The "old" bug object doesn't contain the comment we just added. + $added_comment = Bugzilla::Bug->check($bug_id)->comments->[-1]; } return ($bug, $added_comment); }