From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2178) id 66472385624C; Tue, 15 Aug 2023 15:08:58 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 66472385624C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1692112138; bh=aoc7YO0E2eWtQmuw5CE+NfXo2AZ6AqDd/CiR9fMuZFU=; h=From:To:Subject:Date:From; b=Rux7i+bTEeQWJBMwUMshBRzjL8zKjIfZmibybWnMkXJf/4EHzxLZ33JkNJED8IDZ/ xr+lEihiiYlMqtgrhLVKgLY3heuy506IHqYiPGj5Cf1aLs8tJ0BuLzuhd8s7bfHlq2 GBe9To4dwQjjP/FTL4urtauf+jE6x8a273mrZnhI= MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="utf-8" From: Florian Weimer To: glibc-cvs@sourceware.org Subject: [glibc] io/tst-statvfs: fix statfs().f_type comparison test on some arches X-Act-Checkin: glibc X-Git-Author: =?utf-8?b?0L3QsNCx?= X-Git-Refname: refs/heads/master X-Git-Oldrev: 892e125f1c92f4f77e75ba56ccb80989de63c391 X-Git-Newrev: 8c4e46337f2ef324f5af9863a962f070fd796cc1 Message-Id: <20230815150858.66472385624C@sourceware.org> Date: Tue, 15 Aug 2023 15:08:58 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=8c4e46337f2ef324f5af9863a962f070fd796cc1 commit 8c4e46337f2ef324f5af9863a962f070fd796cc1 Author: наб Date: Tue Aug 15 15:07:59 2023 +0200 io/tst-statvfs: fix statfs().f_type comparison test on some arches On i686 f_type is an i32 so the test fails when that has the top bit set. Explicitly cast to u32. Signed-off-by: Ahelenia Ziemiańska Reviewed-by: Florian Weimer Diff: --- io/tst-statvfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/io/tst-statvfs.c b/io/tst-statvfs.c index f3097ce1a8..fb23733667 100644 --- a/io/tst-statvfs.c +++ b/io/tst-statvfs.c @@ -16,7 +16,7 @@ do_test (int argc, char *argv[]) struct statfs stf; TEST_COMPARE (statvfs (argv[i], &st), 0); TEST_COMPARE (statfs (argv[i], &stf), 0); - TEST_COMPARE (st.f_type, stf.f_type); + TEST_COMPARE (st.f_type, (unsigned int) stf.f_type); printf ("%s: free: %llu, mandatory: %s, tp=%x\n", argv[i], (unsigned long long int) st.f_bfree, #ifdef ST_MANDLOCK