Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Issue 5869 (Parts of headers wrapped in arrow brackets are treated as…

  • Loading branch information...
commit e9b10d7da4a446c944156523027a8cfac9a3355a 1 parent 6950b50
Sebastian Zartner authored August 26, 2012
1  extension/content/firebug/net/netReps.js
@@ -1646,6 +1646,7 @@ Firebug.NetMonitor.NetInfoHeaders = domplate(Firebug.Rep, new Firebug.Listener()
1646 1646
         else
1647 1647
         {
1648 1648
             var source = requestHeaders ? file.requestHeadersText : file.responseHeadersText;
  1649
+            source = source.replace("<", "&lt;", "g").replace(">", "&gt;", "g");
1649 1650
             this.insertSource(netInfoBox, source, target.rowName);
1650 1651
             target.innerHTML = Locale.$STR("net.headers.pretty print");
1651 1652
         }

2 notes on commit e9b10d7

Simon Lindholm
Collaborator

Can't you change insertSource to set .textContent instead? (Otherwise, we have functions for this in lib/string which also correctly escape "&".)

Sebastian Zartner
Collaborator

As always you're the master of clean code. :-)
Did both in 2a3f4bd.
Thanks for the hint.

Sebastian

Please sign in to comment.
Something went wrong with that request. Please try again.