From 96b6cc3cf41f3fc657505d3bb6d2be9b65abe636 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Buclin?= Date: Wed, 4 Aug 2010 01:25:21 +0200 Subject: Bug 584110: Don't name attachment files "attachment.txt" by default, because this confuses IE a=LpSolit --- attachment.cgi | 2 +- post_bug.cgi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/attachment.cgi b/attachment.cgi index 8e69d388f..8117131b3 100755 --- a/attachment.cgi +++ b/attachment.cgi @@ -481,7 +481,7 @@ sub insert { creation_ts => $timestamp, data => scalar $cgi->param('attach_text') || $cgi->upload('data'), description => scalar $cgi->param('description'), - filename => $cgi->param('attach_text') ? 'attachment.txt' : scalar $cgi->upload('data'), + filename => $cgi->param('attach_text') ? "file_$bugid.txt" : scalar $cgi->upload('data'), ispatch => scalar $cgi->param('ispatch'), isprivate => scalar $cgi->param('isprivate'), mimetype => $content_type, diff --git a/post_bug.cgi b/post_bug.cgi index 74d26af2b..2c8062605 100755 --- a/post_bug.cgi +++ b/post_bug.cgi @@ -200,7 +200,7 @@ if (defined($cgi->upload('data')) || $cgi->param('attach_text')) { creation_ts => $timestamp, data => scalar $cgi->param('attach_text') || $cgi->upload('data'), description => scalar $cgi->param('description'), - filename => $cgi->param('attach_text') ? 'attachment.txt' : scalar $cgi->upload('data'), + filename => $cgi->param('attach_text') ? "file_$id.txt" : scalar $cgi->upload('data'), ispatch => scalar $cgi->param('ispatch'), isprivate => scalar $cgi->param('isprivate'), mimetype => $content_type, -- cgit v1.2.1