summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Template.pm
diff options
context:
space:
mode:
authorByron Jones <glob@mozilla.com>2014-11-18 05:45:08 +0100
committerByron Jones <glob@mozilla.com>2014-11-18 05:45:08 +0100
commite4bc2084f4c9f8ec5d411a9b41915eab0104eca0 (patch)
tree65b2ff889fdfade5c3c47f9c3809f0f1d850e6e8 /Bugzilla/Template.pm
parent891689f1fdf09bf06c5e5dd944f6a6ae43f2cfd8 (diff)
downloadbugzilla-e4bc2084f4c9f8ec5d411a9b41915eab0104eca0.tar.gz
bugzilla-e4bc2084f4c9f8ec5d411a9b41915eab0104eca0.tar.xz
Bug 1100368: css concatenation breaks data: urls
Diffstat (limited to 'Bugzilla/Template.pm')
-rw-r--r--Bugzilla/Template.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/Bugzilla/Template.pm b/Bugzilla/Template.pm
index 9bd0c51bd..be84bc66a 100644
--- a/Bugzilla/Template.pm
+++ b/Bugzilla/Template.pm
@@ -521,7 +521,9 @@ sub _css_url_rewrite {
# rewrite relative urls as the unified stylesheet lives in a different
# directory from the source
$url =~ s/(^['"]|['"]$)//g;
- return $url if substr($url, 0, 1) eq '/';
+ if (substr($url, 0, 1) eq '/' || substr($url, 0, 5) eq 'data:') {
+ return 'url(' . $url . ')';
+ }
return 'url(../../' . dirname($source) . '/' . $url . ')';
}