Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ivan Ivlev
bugzilla
Commits
2b68a4d9
Commit
2b68a4d9
authored
Jul 20, 2007
by
timeless%mozdev.org
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 365756 text/x-patch and text/x-diff should be mapped to [x] patch
r=lpsolit a=lpsolit
parent
03714c5a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
Attachment.pm
Bugzilla/Attachment.pm
+9
-0
No files found.
Bugzilla/Attachment.pm
View file @
2b68a4d9
...
...
@@ -748,6 +748,15 @@ sub insert_attachment_for_bug {
# we now check the content type for image/bmp in _validate_data()
unless
(
$cgi
->
param
(
'ispatch'
))
{
$class
->
validate_content_type
(
$throw_error
)
||
return
;
# Set the ispatch flag to 1 if we're set to autodetect
# and the content type is text/x-diff or text/x-patch
if
(
$cgi
->
param
(
'contenttypemethod'
)
eq
'autodetect'
&&
$cgi
->
param
(
'contenttype'
)
=~
m{text/x-(?:diff|patch)}
)
{
$cgi
->
param
(
'ispatch'
,
1
);
$cgi
->
param
(
'contenttype'
,
'text/plain'
);
}
}
$data
=
_validate_data
(
$throw_error
,
$hr_vars
);
# If the attachment is stored locally, $data eq ''.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment