]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
more: Calling open without checking return value [coverity scan]
authorKarel Zak <kzak@redhat.com>
Wed, 18 Aug 2021 08:25:14 +0000 (10:25 +0200)
committerKarel Zak <kzak@redhat.com>
Wed, 18 Aug 2021 08:25:14 +0000 (10:25 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
text-utils/more.c

index 5c068f1f383ee4cfd93b976c901bf18c12ccd554..0d081a53126d9f0c10912b3acaa8934c2f02b39b 100644 (file)
@@ -1229,7 +1229,7 @@ static void __attribute__((__format__ (__printf__, 3, 4)))
                int errsv;
                if (!isatty(STDIN_FILENO)) {
                        close(STDIN_FILENO);
-                       open("/dev/tty", 0);
+                       ignore_result( open("/dev/tty", 0) );
                }
                reset_tty(ctl);