Skip to content

Commit 29bd06b

Browse files
boklmHainish
authored andcommitted
[PATCH] Bug 19976: don't try to load a library with an empty name
1 parent 9acddcd commit 29bd06b

File tree

2 files changed

+6
-10
lines changed

2 files changed

+6
-10
lines changed

src/chrome/content/code/NSS.js

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,13 @@ function NSS() {
2525

2626
}
2727

28-
NSS.initialize = function(nssPath) {
28+
NSS.initialize = function() {
2929
var sharedLib;
3030

31-
try {
32-
sharedLib = tcypes.open(nssPath);
33-
} catch (e) {
34-
Components.utils.import("resource://gre/modules/Services.jsm");
35-
var nssFile = Services.dirsvc.get("GreD", Ci.nsILocalFile);
36-
nssFile.append(tcypes.libraryName("nss3"));
37-
sharedLib = tcypes.open(nssFile.path);
38-
}
31+
Components.utils.import("resource://gre/modules/Services.jsm");
32+
var nssFile = Services.dirsvc.get("GreD", Ci.nsILocalFile);
33+
nssFile.append(tcypes.libraryName("nss3"));
34+
sharedLib = tcypes.open(nssFile.path);
3935

4036
NSS.types = new Object();
4137

src/components/ssl-observatory.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ function SSLObservatory() {
123123
this.setupASNWatcher();
124124

125125
try {
126-
NSS.initialize("");
126+
NSS.initialize();
127127
} catch(e) {
128128
this.log(WARN, "Failed to initialize NSS component:" + e);
129129
}

0 commit comments

Comments
 (0)