From: Karel Zak Date: Tue, 3 Dec 2019 13:31:55 +0000 (+0100) Subject: libmount: fix typo in mnt_context_prepare_helper() [lgtm scan] X-Git-Tag: v2.35-rc1~37 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6f7c67a5ffd7d356b3c91e4bbc8e1653cfc89ec4;p=thirdparty%2Futil-linux.git libmount: fix typo in mnt_context_prepare_helper() [lgtm scan] Signed-off-by: Karel Zak --- diff --git a/libmount/src/context.c b/libmount/src/context.c index 977842f7d8..bfba39c4bd 100644 --- a/libmount/src/context.c +++ b/libmount/src/context.c @@ -2094,7 +2094,7 @@ int mnt_context_prepare_helper(struct libmnt_context *cxt, const char *name, continue; xrc = stat(helper, &st); - if (rc == -1 && errno == ENOENT && strchr(type, '.')) { + if (xrc == -1 && errno == ENOENT && strchr(type, '.')) { /* If type ends with ".subtype" try without it */ char *hs = strrchr(helper, '.'); if (hs)