From 4256314250be97ea76f35100c4332acd17839da9 Mon Sep 17 00:00:00 2001 From: wangdi Date: Wed, 29 Feb 2012 16:32:23 -0800 Subject: [PATCH] LU-1155 obdecho: Oops if target device can not be found. Missing setting error value if target device can not be found, which will cause Oops in some cases. Signed-off-by: Wang Di Change-Id: I5fc7cd376c8c7c276739692c7234ae142b4f6e23 Reviewed-on: http://review.whamcloud.com/2229 Tested-by: Hudson Tested-by: Maloo Reviewed-by: Oleg Drokin --- lustre/obdecho/echo_client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lustre/obdecho/echo_client.c b/lustre/obdecho/echo_client.c index 67b746c..ea9f293 100644 --- a/lustre/obdecho/echo_client.c +++ b/lustre/obdecho/echo_client.c @@ -783,7 +783,7 @@ static struct lu_device *echo_device_alloc(const struct lu_env *env, if (tgt == NULL) { CERROR("Can not find tgt device %s\n", lustre_cfg_string(cfg, 1)); - GOTO(out, rc); + GOTO(out, rc = -ENODEV); } next = tgt->obd_lu_dev; -- 1.8.3.1