diff options
author | Arfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org> | 2012-06-29 01:23:28 +0200 |
---|---|---|
committer | Anthony G. Basile <blueness@gentoo.org> | 2012-06-29 08:50:24 -0400 |
commit | 21a203cfb79726d6798ca878e52b8ab39ef9b15a (patch) | |
tree | 3bd9d85e07dce1fbfad776c1426e57e8dcd183a3 /WebappConfig | |
parent | Use print() function for compatibility with Python 3. (diff) | |
download | webapp-config-21a203cfb79726d6798ca878e52b8ab39ef9b15a.tar.gz webapp-config-21a203cfb79726d6798ca878e52b8ab39ef9b15a.tar.bz2 webapp-config-21a203cfb79726d6798ca878e52b8ab39ef9b15a.zip |
Use str.join() instead of string.join() for compatibility with Python 3.
Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'WebappConfig')
-rw-r--r-- | WebappConfig/sandbox.py | 4 | ||||
-rw-r--r-- | WebappConfig/wrapper.py | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/WebappConfig/sandbox.py b/WebappConfig/sandbox.py index 698a566..bb92c50 100644 --- a/WebappConfig/sandbox.py +++ b/WebappConfig/sandbox.py @@ -24,7 +24,7 @@ __version__ = "$Id: permissions.py 129 2005-11-06 12:46:31Z wrobel $" # Dependencies # ------------------------------------------------------------------------ -import os, os.path, string, sys +import os, os.path, sys # stolen from portage if os.path.isdir("/proc/%i/fd" % os.getpid()): @@ -55,7 +55,7 @@ class Sandbox: def get_write(self): '''Return write paths.''' - return string.join ( map ( self.get_config, self.__write ), ':' ) \ + return ':'.join ( map ( self.get_config, self.__write ) ) \ + self.__syswrite def get_config(self, option): diff --git a/WebappConfig/wrapper.py b/WebappConfig/wrapper.py index fd4b010..1897dd6 100644 --- a/WebappConfig/wrapper.py +++ b/WebappConfig/wrapper.py @@ -26,7 +26,7 @@ __version__ = "$Id: wrapper.py 283 2006-04-20 22:53:04Z wrobel $" # Dependencies # ------------------------------------------------------------------------ -import os, string +import os from WebappConfig.debug import OUT @@ -62,7 +62,7 @@ def config_protect(cat, pn, pvr, pm): fo.close() fe.close() - return string.join(result_lines, ' ').strip() + return ' '.join(result_lines).strip() else: OUT.die("Unknown package manager: " + pm) @@ -156,7 +156,7 @@ def package_installed(full_name, pm): for i in error_lines: OUT.warn(i) - return string.join(result_lines, ' ') + return ' '.join(result_lines) else: OUT.die("Unknown package manager: " + pm) |