aboutsummaryrefslogtreecommitdiffstats
path: root/fs/locks.c
diff options
context:
space:
mode:
authorNathan Scott <nathans@sgi.com>2006-06-20 00:56:23 -0400
committerNathan Scott <nathans@sgi.com>2006-06-20 00:56:23 -0400
commit98174e46974323e4941c72e46345f7277755e146 (patch)
treec4644c8f38a519cfb3929d1175fc7107eefe48b9 /fs/locks.c
parentd8ce75324135ea7100124c1fff4ec5090a350607 (diff)
parent25f42b6af09e34c3f92107b36b5aa6edc2fdba2f (diff)
Merge HEAD from ../linux-2.6
Diffstat (limited to 'fs/locks.c')
-rw-r--r--fs/locks.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/locks.c b/fs/locks.c
index 6f99c0a6f836..ab61a8b54829 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -755,6 +755,7 @@ static int flock_lock_file(struct file *filp, struct file_lock *request)
755 if (request->fl_type == F_UNLCK) 755 if (request->fl_type == F_UNLCK)
756 goto out; 756 goto out;
757 757
758 error = -ENOMEM;
758 new_fl = locks_alloc_lock(); 759 new_fl = locks_alloc_lock();
759 if (new_fl == NULL) 760 if (new_fl == NULL)
760 goto out; 761 goto out;
@@ -781,6 +782,7 @@ static int flock_lock_file(struct file *filp, struct file_lock *request)
781 locks_copy_lock(new_fl, request); 782 locks_copy_lock(new_fl, request);
782 locks_insert_lock(&inode->i_flock, new_fl); 783 locks_insert_lock(&inode->i_flock, new_fl);
783 new_fl = NULL; 784 new_fl = NULL;
785 error = 0;
784 786
785out: 787out:
786 unlock_kernel(); 788 unlock_kernel();