From: Karel Zak Date: Thu, 23 Mar 2017 14:28:05 +0000 (+0100) Subject: fincore: fix error on open() X-Git-Tag: v2.30-rc1~168 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cff1c113fe0686d0524a4a70973f2345fcc4c7c9;p=thirdparty%2Futil-linux.git fincore: fix error on open() Signed-off-by: Karel Zak --- diff --git a/misc-utils/fincore.c b/misc-utils/fincore.c index ddb2bb267c..a2fc1d1113 100644 --- a/misc-utils/fincore.c +++ b/misc-utils/fincore.c @@ -221,7 +221,7 @@ static int fincore_name(struct fincore_control *ctl, if ((fd = open (name, O_RDONLY)) < 0) { warn(_("failed to open: %s"), name); - return 0; + return -errno; } if (fstat (fd, sb) < 0) {