X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lnet%2Futils%2Flnetconfig%2Fliblnetconfig.c;fp=lnet%2Futils%2Flnetconfig%2Fliblnetconfig.c;h=7ed9c05fac444af0e0d7eafa5e046278937aa4cb;hb=1db59b7b603a917d4ab1bba98d94dd169475b86b;hp=36bb8919c35db09a100bb89716f239a56fbe3ca1;hpb=8e53a0ea594a7d7eb9cd7541233bc8771d4023b5;p=fs%2Flustre-release.git diff --git a/lnet/utils/lnetconfig/liblnetconfig.c b/lnet/utils/lnetconfig/liblnetconfig.c index 36bb891..7ed9c05 100644 --- a/lnet/utils/lnetconfig/liblnetconfig.c +++ b/lnet/utils/lnetconfig/liblnetconfig.c @@ -4263,7 +4263,6 @@ int lustre_lnet_show_stats(int seq_no, struct cYAML **show_rc, struct lnet_ioctl_lnet_stats data; struct lnet_counters *cntrs; int rc; - int l_errno; char err_str[LNET_MAX_STR_LEN] = "\"out of memory\""; struct cYAML *root = NULL, *stats = NULL; @@ -4271,12 +4270,10 @@ int lustre_lnet_show_stats(int seq_no, struct cYAML **show_rc, rc = l_ioctl(LNET_DEV_ID, IOC_LIBCFS_GET_LNET_STATS, &data); if (rc) { - l_errno = errno; snprintf(err_str, sizeof(err_str), "\"cannot get lnet statistics: %s\"", - strerror(l_errno)); - rc = -l_errno; + strerror(-rc)); goto out; }