patch-2.1.81 linux/fs/open.c
Next file: linux/fs/proc/array.c
Previous file: linux/fs/ntfs/fs.c
Back to the patch index
Back to the overall index
- Lines: 24
- Date:
Fri Jan 23 16:23:21 1998
- Orig file:
v2.1.80/linux/fs/open.c
- Orig date:
Sun Jan 4 00:53:41 1998
diff -u --recursive --new-file v2.1.80/linux/fs/open.c linux/fs/open.c
@@ -546,6 +546,23 @@
int error;
lock_kernel();
+ dentry = namei(filename);
+
+ error = PTR_ERR(dentry);
+ if (!IS_ERR(dentry)) {
+ error = chown_common(dentry, user, group);
+ dput(dentry);
+ }
+ unlock_kernel();
+ return error;
+}
+
+asmlinkage int sys_lchown(const char * filename, uid_t user, gid_t group)
+{
+ struct dentry * dentry;
+ int error;
+
+ lock_kernel();
dentry = lnamei(filename);
error = PTR_ERR(dentry);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov