From: Amir Shehata Date: Thu, 4 Oct 2018 00:17:03 +0000 (-0700) Subject: LU-11469 lnet: fix "debug recovery" output X-Git-Tag: 2.12.0-RC1~96 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=307d877e51240e1d50c0fc42b190f1247f387f85;hp=7f8143cf85b7e658976aa6526689628a81ed6a32 LU-11469 lnet: fix "debug recovery" output Don't print out anything from lnetctl debug recovery [--local|--peer] if there are no NIs on the recovery queues. Test-Parameters: trivial Signed-off-by: Amir Shehata Change-Id: Icf4d5e2f1e3eefafce81dcc73525a4dd9a36d009 Reviewed-on: https://review.whamcloud.com/33310 Reviewed-by: Doug Oucharek Reviewed-by: Sonia Sharma Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Olaf Weber Reviewed-by: Oleg Drokin --- diff --git a/lnet/utils/lnetconfig/liblnetconfig.c b/lnet/utils/lnetconfig/liblnetconfig.c index 4978c42..a3d8a5c 100644 --- a/lnet/utils/lnetconfig/liblnetconfig.c +++ b/lnet/utils/lnetconfig/liblnetconfig.c @@ -3476,6 +3476,9 @@ int show_recovery_queue(enum lnet_health_type type, char *name, int seq_no, goto out; } + if (nid_list.rlst_num_nids == 0) + goto out; + root = cYAML_create_object(NULL, NULL); if (root == NULL) goto out;