We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8c3cdbe commit 1d8b52bCopy full SHA for 1d8b52b
lib/index.js
@@ -1,3 +1,4 @@
1
+'use strict';
2
var binary = require('node-pre-gyp');
3
var path = require('path');
4
var bindingPath =
@@ -13,8 +14,8 @@ var request = Promise.promisify(bindings.request);
13
14
15
// Hacky way to make strings safe for eval.
16
var addslashes = function(s) {
- return "'" + s.replace(/[\'\\\000]/g, function(c) {
17
- if (c === '\000') {
+ return "'" + s.replace(/[\'\\\x00]/g, function(c) {
18
+ if (c === '\x00') {
19
return '\'."\0".\'';
20
}
21
return '\\' + c;
0 commit comments