- ret = SMB_VFS_CHOWN( conn, fname, uid, gid);
+ smb_fname = synthetic_smb_fname(talloc_tos(),
+ fname,
+ NULL,
+ NULL,
+ lp_posix_pathnames() ?
+ SMB_FILENAME_POSIX_PATH : 0);
+ if (smb_fname == NULL) {
+ umask(saved_umask);
+ TALLOC_FREE(frame);
+ errno = ENOMEM;
+ return PyErr_SetFromErrno(PyExc_OSError);
+ }
+
+ ret = SMB_VFS_CHOWN(conn, smb_fname, uid, gid);