From 6725cbd7f7e52741ee13f79ea030b908691232bf Mon Sep 17 00:00:00 2001 From: RaNaN Date: Sat, 21 Aug 2010 18:23:28 +0200 Subject: removed tempfile, win fixes --- module/plugins/Plugin.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'module/plugins/Plugin.py') diff --git a/module/plugins/Plugin.py b/module/plugins/Plugin.py index 31aae2ee9..42809b248 100644 --- a/module/plugins/Plugin.py +++ b/module/plugins/Plugin.py @@ -204,7 +204,7 @@ class Plugin(object): content = self.load(url, get=get, post=post, cookies=cookies) temp = NamedTemporaryFile() - temp = open("tmpCaptcha_%s" % self.__name__, "wb") + temp = open(join("tmp","tmpCaptcha_%s" % self.__name__ ), "wb") temp.write(content) temp.close() @@ -232,9 +232,10 @@ class Plugin(object): sleep(1) result = task.getResult() task.removeTask() + + if not self.core.debug: + remove(temp.name) - remove(temp.name) - #temp.unlink(temp.name) return result -- cgit v1.2.3