How to control permission of file?
Grant Edwards
grante at visi.com
Fri Jun 30 16:15:21 EDT 2006
On 2006-06-30, K.S.Sreeram <sreeram at tachyontech.net> wrote:
> Grant Edwards wrote:
>> When one open()s a file (that doesn't exist) for writing , how
>> does one control that file's permissions (it's "mode" in Unix
>> terms).
>
> Check out 'os.open'
> It returns a file descriptor, and if you need a file object you can use
> 'os.fdopen' on the file descriptor
Thanks. I thought maybe there was a less arcane way to do it.
--
Grant Edwards grante Yow! FROZEN ENTREES may
at be flung by members of
visi.com opposing SWANSON SECTS...
More information about the Python-list
mailing list