Red Hat Bugzilla – Bug 165069
mock throws IO error when run with restrictive umask
Last modified: 2007-11-30 17:11:11 EST
Description of problem:
mock errors out if user's umask is too restrictive.
Steps to Reproduce:
1. umask 0077
2. mock some.src.srpm
Traceback (most recent call last):
File "mock.py", line 786, in ?
File "mock.py", line 774, in main
File "mock.py", line 308, in build
srpm_out = self.install_build_deps(srpm)
File "mock.py", line 233, in install_build_deps
File "/usr/lib64/python2.4/shutil.py", line 92, in copy2
File "/usr/lib64/python2.4/shutil.py", line 48, in copyfile
fdst = open(dst, 'wb')
IOError: [Errno 13] Permission denied:
Should rebuild srpm
It'd be nice if this would work even when user's umask is restrictive. I'm
proposing this patch which sets the umask to 0022 before doing work in the chroot.
Created attachment 117429 [details]
not notabug - next release