diff options
author | Steven Whitehouse <swhiteho@redhat.com> | 2009-06-15 03:26:48 -0400 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2009-06-17 12:31:32 -0400 |
commit | a566a6b11c86147fe9fc9db7ab15f9eecca3e862 (patch) | |
tree | 3583e7e0ac8d557610df16054fd96df98062edc5 /fs/dlm/lock.c | |
parent | 65795efbd380a832ae508b04dba8f8e53f0b84d9 (diff) |
dlm: Fix uninitialised variable warning in lock.c
CC [M] fs/dlm/lock.o
fs/dlm/lock.c: In function ‘find_rsb’:
fs/dlm/lock.c:438: warning: ‘r’ may be used uninitialized in this function
Since r is used on the error path to set r_ret, set it to NULL.
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm/lock.c')
-rw-r--r-- | fs/dlm/lock.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c index 205ec95b347..eb507c453c5 100644 --- a/fs/dlm/lock.c +++ b/fs/dlm/lock.c | |||
@@ -435,7 +435,7 @@ static int search_rsb(struct dlm_ls *ls, char *name, int len, int b, | |||
435 | static int find_rsb(struct dlm_ls *ls, char *name, int namelen, | 435 | static int find_rsb(struct dlm_ls *ls, char *name, int namelen, |
436 | unsigned int flags, struct dlm_rsb **r_ret) | 436 | unsigned int flags, struct dlm_rsb **r_ret) |
437 | { | 437 | { |
438 | struct dlm_rsb *r, *tmp; | 438 | struct dlm_rsb *r = NULL, *tmp; |
439 | uint32_t hash, bucket; | 439 | uint32_t hash, bucket; |
440 | int error = -EINVAL; | 440 | int error = -EINVAL; |
441 | 441 | ||