pld-ftp-admin: modules/cmds.py, modules/common.py - paths thing on ftpadmdir
glen
glen at pld-linux.org
Tue Jun 30 05:47:52 CEST 2009
Author: glen Date: Tue Jun 30 03:47:52 2009 GMT
Module: pld-ftp-admin Tag: HEAD
---- Log message:
- paths thing on ftpadmdir
---- Files affected:
pld-ftp-admin/modules:
cmds.py (1.13 -> 1.14) , common.py (1.10 -> 1.11)
---- Diffs:
================================================================
Index: pld-ftp-admin/modules/cmds.py
diff -u pld-ftp-admin/modules/cmds.py:1.13 pld-ftp-admin/modules/cmds.py:1.14
--- pld-ftp-admin/modules/cmds.py:1.13 Sun Sep 11 16:33:38 2005
+++ pld-ftp-admin/modules/cmds.py Tue Jun 30 05:47:46 2009
@@ -81,19 +81,19 @@
global users, cookies
users={}
cookies={}
- if not common.fileexists(common.ftpadmdir+'var/passwd'):
+ if not common.fileexists(common.ftpadmdir+'/var/passwd'):
return
else:
- f=open(common.ftpadmdir+'var/passwd', 'r')
+ f=open(common.ftpadmdir+'/var/passwd', 'r')
for line in f.xreadlines():
x=line.strip().split(':')
if len(x)>=2:
users[x[0]]=x[1]
f.close()
- if not common.fileexists(common.ftpadmdir+'var/cookies'):
+ if not common.fileexists(common.ftpadmdir+'/var/cookies'):
return
else:
- f=open(common.ftpadmdir+'var/cookies', 'r')
+ f=open(common.ftpadmdir+'/var/cookies', 'r')
for line in f.xreadlines():
x=line.strip().split(':')
if len(x)>=2:
@@ -101,7 +101,7 @@
f.close()
def write_cookies():
- f=open(common.ftpadmdir+'var/cookies', 'w')
+ f=open(common.ftpadmdir+'/var/cookies', 'w')
for key in cookies.keys():
f.write('%s:%s\n' % (key, cookies[key]))
f.close()
@@ -178,7 +178,7 @@
BailOut="BailOut"
locks={}
-logfile=open(common.ftpadmdir+'var/log', 'a')
+logfile=open(common.ftpadmdir+'/var/log', 'a')
load_creds()
reloadftptree()
salt=md5.new(`time.time()`).hexdigest()
================================================================
Index: pld-ftp-admin/modules/common.py
diff -u pld-ftp-admin/modules/common.py:1.10 pld-ftp-admin/modules/common.py:1.11
--- pld-ftp-admin/modules/common.py:1.10 Wed May 27 00:42:54 2009
+++ pld-ftp-admin/modules/common.py Tue Jun 30 05:47:46 2009
@@ -15,12 +15,12 @@
sys.exit(1)
if 'HOME' in os.environ:
- ftpadmdir = os.environ['HOME'] + '/pld-ftp-admin/'
+ ftpadmdir = os.environ['HOME'] + '/pld-ftp-admin'
else:
- ftpadmdir = '../'
+ ftpadmdir = '..'
# noarchcachedir is dir where noarch files contents are stored for AI
# XXX: file reference where the AI resides
-noarchcachedir = ftpadmdir + 'var/noarch-cache/'
+noarchcachedir = ftpadmdir + '/var/noarch-cache/'
-tmpdir = ftpadmdir + 'var/tmp/'
+tmpdir = ftpadmdir + '/var/tmp/'
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/pld-ftp-admin/modules/cmds.py?r1=1.13&r2=1.14&f=u
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/pld-ftp-admin/modules/common.py?r1=1.10&r2=1.11&f=u
More information about the pld-cvs-commit
mailing list