Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9a19fbb
)
Branch b_release_1_4_6
author
adilger
<adilger>
Wed, 25 Jan 2006 11:16:26 +0000
(11:16 +0000)
committer
adilger
<adilger>
Wed, 25 Jan 2006 11:16:26 +0000
(11:16 +0000)
Fix potential NULL deref in ldlm_resource_foreach() (COV:707)
b=10098
lustre/ldlm/ldlm_request.c
patch
|
blob
|
history
diff --git
a/lustre/ldlm/ldlm_request.c
b/lustre/ldlm/ldlm_request.c
index
607683e
..
07cfbb7
100644
(file)
--- a/
lustre/ldlm/ldlm_request.c
+++ b/
lustre/ldlm/ldlm_request.c
@@
-984,13
+984,14
@@
int ldlm_resource_foreach(struct ldlm_resource *res, ldlm_iterator_t iter,
struct list_head *tmp, *next;
struct ldlm_lock *lock;
int rc = LDLM_ITER_CONTINUE;
- struct ldlm_namespace *ns
= res->lr_namespace
;
+ struct ldlm_namespace *ns;
ENTRY;
if (!res)
RETURN(LDLM_ITER_CONTINUE);
+ ns = res->lr_namespace;
l_lock(&ns->ns_lock);
list_for_each_safe(tmp, next, &res->lr_granted) {
lock = list_entry(tmp, struct ldlm_lock, l_res_link);