From 7f0709dfcba040ab91aace8bc5037ad2f5fd8cbb Mon Sep 17 00:00:00 2001 From: Jos Schellevis Date: Thu, 2 Jul 2015 09:25:23 +0200 Subject: [PATCH] (proxy) add path for deteting old acl files --- src/opnsense/scripts/proxy/fetchACLs.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/opnsense/scripts/proxy/fetchACLs.py b/src/opnsense/scripts/proxy/fetchACLs.py index 670e0a16e..9a1168ae7 100755 --- a/src/opnsense/scripts/proxy/fetchACLs.py +++ b/src/opnsense/scripts/proxy/fetchACLs.py @@ -54,9 +54,9 @@ if os.path.exists(acl_config_fn): f = urllib2.urlopen(cnf.get(section,'url'),timeout = acl_max_timeout) with open('%s/%s'%(acl_target_dir,section), "wb") as code: code.write(f.read()) - # if disabled try to remove old file - elif cnf.get(section,'enabled')=='0': + # if disabled or not 1 try to remove old file + elif cnf.get(section,'enabled')!='1': try: - os.remove(section) + os.remove(acl_target_dir+'/'+section) except OSError: pass