summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>2009-09-20 12:39:22 +0000
committerArfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>2009-09-20 12:39:22 +0000
commit5ce55d59b6a1e0fabd4e7879aa94f69251d03d69 (patch)
treedba0a7625f7512cadba06e7b4b6a9dd0cf24b12c
parent199228d412c83e00f0c4af7ba34f166a891b4e87 (diff)
downloadportage-5ce55d59b6a1e0fabd4e7879aa94f69251d03d69.tar.gz
portage-5ce55d59b6a1e0fabd4e7879aa94f69251d03d69.tar.bz2
portage-5ce55d59b6a1e0fabd4e7879aa94f69251d03d69.zip
Update syntax of numbers in some files which were missing in previous commit.
svn path=/main/trunk/; revision=14293
-rw-r--r--pym/_emerge/actions.py16
-rw-r--r--pym/_emerge/emergelog.py2
2 files changed, 9 insertions, 9 deletions
diff --git a/pym/_emerge/actions.py b/pym/_emerge/actions.py
index 3255a9b9e..08f11836e 100644
--- a/pym/_emerge/actions.py
+++ b/pym/_emerge/actions.py
@@ -1442,7 +1442,7 @@ def action_metadata(settings, portdb, myopts, porttrees=None):
if porttrees is None:
porttrees = portdb.porttrees
portage.writemsg_stdout("\n>>> Updating Portage cache\n")
- old_umask = os.umask(0002)
+ old_umask = os.umask(0o002)
cachedir = os.path.normpath(settings.depcachedir)
if cachedir in ["/", "/bin", "/dev", "/etc", "/home",
"/lib", "/opt", "/proc", "/root", "/sbin",
@@ -1717,15 +1717,15 @@ def action_sync(settings, trees, mtimedb, myopts, myaction):
st = None
if st is None:
print(">>>",myportdir,"not found, creating it.")
- os.makedirs(myportdir,0755)
+ os.makedirs(myportdir,0o755)
st = os.stat(myportdir)
spawn_kwargs = {}
spawn_kwargs["env"] = settings.environ()
if 'usersync' in settings.features and \
portage.data.secpass >= 2 and \
- (st.st_uid != os.getuid() and st.st_mode & 0700 or \
- st.st_gid != os.getgid() and st.st_mode & 0070):
+ (st.st_uid != os.getuid() and st.st_mode & 0o700 or \
+ st.st_gid != os.getgid() and st.st_mode & 0o070):
try:
homedir = pwd.getpwuid(st.st_uid).pw_dir
except KeyError:
@@ -1737,9 +1737,9 @@ def action_sync(settings, trees, mtimedb, myopts, myaction):
spawn_kwargs["gid"] = st.st_gid
spawn_kwargs["groups"] = [st.st_gid]
spawn_kwargs["env"]["HOME"] = homedir
- umask = 0002
- if not st.st_mode & 0020:
- umask = umask | 0020
+ umask = 0o002
+ if not st.st_mode & 0o020:
+ umask = umask | 0o020
spawn_kwargs["umask"] = umask
syncuri = settings.get("SYNC", "").strip()
@@ -1751,7 +1751,7 @@ def action_sync(settings, trees, mtimedb, myopts, myaction):
vcs_dirs = frozenset([".git", ".svn", "CVS", ".hg"])
vcs_dirs = vcs_dirs.intersection(os.listdir(myportdir))
- os.umask(0022)
+ os.umask(0o022)
dosyncuri = syncuri
updatecache_flg = False
if myaction == "metadata":
diff --git a/pym/_emerge/emergelog.py b/pym/_emerge/emergelog.py
index bfe6fb441..5b026bf6c 100644
--- a/pym/_emerge/emergelog.py
+++ b/pym/_emerge/emergelog.py
@@ -33,7 +33,7 @@ def emergelog(xterm_titles, mystr, short_msg=None):
errors='backslashreplace')
portage.util.apply_secpass_permissions(file_path,
uid=portage.portage_uid, gid=portage.portage_gid,
- mode=0660)
+ mode=0o660)
mylock = None
try:
mylock = portage.locks.lockfile(mylogfile)