public
/
UglifyJS.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
75cdbf1
)
Don't unescape byte order marks in regexps
author
Ville Lautanala
<lautis@gmail.com>
Sun, 19 Jan 2014 10:27:03 +0000
(12:27 +0200)
committer
Ville Lautanala
<lautis@gmail.com>
Sun, 19 Jan 2014 10:27:03 +0000
(12:27 +0200)
lib/output.js
patch
|
blob
|
history
diff --git
a/lib/output.js
b/lib/output.js
index
896defa
..
fce2c1a
100644
(file)
--- a/
lib/output.js
+++ b/
lib/output.js
@@
-1126,7
+1126,7
@@
function OutputStream(options) {
str = str.split("\\\\").map(function(str){
return str.replace(/\\u[0-9a-fA-F]{4}|\\x[0-9a-fA-F]{2}/g, function(s){
var code = parseInt(s.substr(2), 16);
- return code == 0x2f || code == 10 || code == 13 || code == 0x2028 || code == 0x2029 ? s : String.fromCharCode(code);
+ return code == 0x
feff || code == 0x
2f || code == 10 || code == 13 || code == 0x2028 || code == 0x2029 ? s : String.fromCharCode(code);
});
}).join("\\\\");
}