aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert Love <rml@novell.com>2005-08-15 12:27:54 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-08-15 12:48:31 -0400
commit0bf955ce98cb3cf40e20d0cc435299eb76e8819e (patch)
treec1fd8207f7d7b3e1db7d0f28ffae88f0dc205083
parent2ba84684e8cf6f980e4e95a2300f53a505eb794e (diff)
[PATCH] inotify: fix idr_get_new_above usage
We are saving the wrong thing in ->last_wd. We want the wd, not the return value. Signed-off-by: Robert Love <rml@novell.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--fs/inotify.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/inotify.c b/fs/inotify.c
index 27ebcac5e07f..868901b1e779 100644
--- a/fs/inotify.c
+++ b/fs/inotify.c
@@ -402,7 +402,7 @@ static struct inotify_watch *create_watch(struct inotify_device *dev,
402 return ERR_PTR(ret); 402 return ERR_PTR(ret);
403 } 403 }
404 404
405 dev->last_wd = ret; 405 dev->last_wd = watch->wd;
406 watch->mask = mask; 406 watch->mask = mask;
407 atomic_set(&watch->count, 0); 407 atomic_set(&watch->count, 0);
408 INIT_LIST_HEAD(&watch->d_list); 408 INIT_LIST_HEAD(&watch->d_list);