use errno.EACCES as suggested by Brian Harring (WarnerBro)
svn path=/main/branches/prefix/; revision=5816
# Distributed under the terms of the GNU General Public License v2
# $Id: /var/cvsroot/gentoo-src/portage/bin/env-update,v 1.9 2004/10/04 13:56:50 vapier Exp $
-import os,sys
+import os, sys, errno
def usage(status):
print "Usage: env-update [--no-ldconfig]"
try:
portage.env_update(makelinks)
except IOError, e:
- if e.errno == 13:
+ if e.errno == errno.EACCES:
print "env-update: Need superuser access"
sys.exit(1)
else: