mirror of
https://github.com/python/cpython.git
synced 2025-11-01 02:38:53 +00:00
Oops, the previous patch contained a bug in chmod. Fixed now.
This commit is contained in:
parent
ffd15f5255
commit
49679b40b9
1 changed files with 2 additions and 2 deletions
|
|
@ -695,10 +695,10 @@ posix_chmod(self, args)
|
|||
char *path;
|
||||
int i;
|
||||
int res;
|
||||
if (!PyArg_ParseTuple(args, format, &path, &i))
|
||||
if (!PyArg_ParseTuple(args, "si", &path, &i))
|
||||
return NULL;
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
res = chmod(path, i);
|
||||
res = chmod(path, (mode_t)i);
|
||||
Py_END_ALLOW_THREADS
|
||||
if (res < 0)
|
||||
return posix_error_with_filename(path);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue