- (bal) sftp-server.c change to use chmod() if fchmod() does not exist.
This commit is contained in:
Ben Lindstrom 2001-01-15 01:56:46 +00:00
parent 7b61cfa1ec
commit 200e3c9c9a
2 changed files with 7 additions and 0 deletions

View File

@ -1,3 +1,6 @@
20010115
- (bal) sftp-server.c change to use chmod() if fchmod() does not exist.
20010114
- (stevesk) initial work for OpenBSD "support supplementary group in
{Allow,Deny}Groups" patch:

View File

@ -685,7 +685,11 @@ process_fsetstat(void)
status = SSH2_FX_FAILURE;
} else {
if (a->flags & SSH2_FILEXFER_ATTR_PERMISSIONS) {
#ifdef HAVE_FCHMOD
ret = fchmod(fd, a->perm & 0777);
#else
ret = chmod(name, a->perm & 077);
#endif
if (ret == -1)
status = errno_to_portable(errno);
}