From 988687592758eaa3058925077f7fbc2aea5429a1 Mon Sep 17 00:00:00 2001 From: Kris Maglione Date: Mon, 24 Oct 2011 11:21:06 -0400 Subject: [PATCH] Don't walk through dot-directories when loading plugins. Grr. --- common/content/dactyl.js | 4 +++- common/modules/io.jsm | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/common/content/dactyl.js b/common/content/dactyl.js index b9d95718..16461c7d 100644 --- a/common/content/dactyl.js +++ b/common/content/dactyl.js @@ -800,7 +800,9 @@ var Dactyl = Module("dactyl", XPCOM(Ci.nsISupportsWeakReference, ModuleBase), { loadplugins = { __proto__: loadplugins, value: args.map(Option.parseRegexp) }; dir.readDirectory(true).forEach(function (file) { - if (file.isFile() && loadplugins.getKey(file.path) + if (file.leafName[0] == ".") + ; + else if (file.isFile() && loadplugins.getKey(file.path) && !(!force && file.path in dactyl.pluginFiles && dactyl.pluginFiles[file.path] >= file.lastModifiedTime)) { try { io.source(file.path); diff --git a/common/modules/io.jsm b/common/modules/io.jsm index f2154f35..10a0897e 100644 --- a/common/modules/io.jsm +++ b/common/modules/io.jsm @@ -166,7 +166,7 @@ var IO = Module("io", { dactyl.echomsg(_("io.sourcing", filename.quote()), 2); - let uri = services.io.newFileURI(file); + let uri = file.URI; let sourceJSM = function sourceJSM() { context = contexts.Module(uri);