From 06d6f4ffda1b1542d9345f246f1c9645d96aeec0 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Mon, 27 Jun 2011 20:27:38 +0200 Subject: closed #345 --- module/network/RequestFactory.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'module/network/RequestFactory.py') diff --git a/module/network/RequestFactory.py b/module/network/RequestFactory.py index 44f66efab..6bb7ced62 100644 --- a/module/network/RequestFactory.py +++ b/module/network/RequestFactory.py @@ -61,8 +61,11 @@ class RequestFactory(): def getURL(self, *args, **kwargs): """ see HTTPRequest for argument list """ h = HTTPRequest(None, self.getOptions()) - rep = h.load(*args, **kwargs) - h.close() + try: + rep = h.load(*args, **kwargs) + finally: + h.close() + return rep def getCookieJar(self, pluginName, account=None): -- cgit v1.2.3