diff options
author | Sage Weil <sage@newdream.net> | 2010-05-25 12:24:42 -0400 |
---|---|---|
committer | Sage Weil <sage@newdream.net> | 2010-05-29 12:12:36 -0400 |
commit | e95e9a7ae4c1e7655a0438579f891b3c60178d77 (patch) | |
tree | 7704aabe47fe7ad8347717b4b6e2b58224b78d9b /fs | |
parent | aa91647c898d62e869fcf35e977ab3c533be8fc1 (diff) |
ceph: avoid possible null dereference
ac->ops may be null; use protocol id in error message instead.
Reported-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ceph/auth.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ceph/auth.c b/fs/ceph/auth.c index 9f46de2ba7a7..01c4a1cd53c0 100644 --- a/fs/ceph/auth.c +++ b/fs/ceph/auth.c | |||
@@ -217,8 +217,8 @@ int ceph_handle_auth_reply(struct ceph_auth_client *ac, | |||
217 | if (ac->protocol != protocol) { | 217 | if (ac->protocol != protocol) { |
218 | ret = ceph_auth_init_protocol(ac, protocol); | 218 | ret = ceph_auth_init_protocol(ac, protocol); |
219 | if (ret) { | 219 | if (ret) { |
220 | pr_err("error %d on auth method %s init\n", | 220 | pr_err("error %d on auth protocol %d init\n", |
221 | ret, ac->ops->name); | 221 | ret, protocol); |
222 | goto out; | 222 | goto out; |
223 | } | 223 | } |
224 | } | 224 | } |