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:
97f9d8b
)
Don't dereference conn if we don't have a connection.
author
adilger
<adilger>
Tue, 5 Mar 2002 23:51:16 +0000
(23:51 +0000)
committer
adilger
<adilger>
Tue, 5 Mar 2002 23:51:16 +0000
(23:51 +0000)
lustre/obdclass/genops.c
patch
|
blob
|
history
diff --git
a/lustre/obdclass/genops.c
b/lustre/obdclass/genops.c
index
6acfa7a
..
64b6db4
100644
(file)
--- a/
lustre/obdclass/genops.c
+++ b/
lustre/obdclass/genops.c
@@
-64,10
+64,14
@@
void obd_cleanup_obdo_cache(void)
/* map connection to client */
struct obd_client *gen_client(const struct obd_conn *conn)
{
- struct obd_device * obddev
= conn->oc_dev
;
+ struct obd_device * obddev;
struct list_head * lh, * next;
struct obd_client * cli;
+ if (!conn)
+ return NULL;
+
+ obddev = conn->oc_dev;
lh = next = &obddev->obd_gen_clients;
while ((lh = lh->next) != &obddev->obd_gen_clients) {
cli = list_entry(lh, struct obd_client, cli_chain);