Kaydet (Commit) 7970d207 authored tarafından Andrew MacIntyre's avatar Andrew MacIntyre

OS/2 has no concept of file ownership, like DOS & MS Windows version

prior to NT.  EMX has a number of Posix emulation routines, including
geteuid() but lacks chown(), so silently skip trying to actually set
a file ownership when extracting a file from a tar archive.
üst 4f28c4da
......@@ -1505,7 +1505,8 @@ class TarFile(object):
if tarinfo.issym() and hasattr(os, "lchown"):
os.lchown(targetpath, u, g)
else:
os.chown(targetpath, u, g)
if sys.platform != "os2emx":
os.chown(targetpath, u, g)
except EnvironmentError, e:
raise ExtractError, "could not change owner"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment