termios_test.cpp: move signedness cast.
Cast the constant (which should probably be unsigned in the kernel headers, but isn't), rather than the already [correctly] unsigned expression involving `c_cflag`. This came up when there was a suggestion on the linux-api mailing list [https://lore.kernel.org/linux-api/be31d737-8263-4e59-8b30-7221ee0549fc@cs.ucla.edu/T/#mdd466d7eaefe8805de7b0cecf013c5cddb04c660] to maybe change the signedness of the constants; this was the only build breakage that would result in AOSP from doing so. Change-Id: I64aeee0a8f5d2edd54a9a9352b1aa2b9e3aa245e
This commit is contained in:
parent
b8f71f8d79
commit
7d9aa55df0
1 changed files with 1 additions and 1 deletions
|
@ -96,7 +96,7 @@ TEST(termios, cfmakeraw) {
|
|||
EXPECT_EQ(0U, (t.c_oflag & OPOST));
|
||||
EXPECT_EQ(0U, (t.c_lflag & (ECHO|ECHONL|ICANON|ISIG|IEXTEN)));
|
||||
EXPECT_EQ(0U, (t.c_cflag & PARENB));
|
||||
EXPECT_EQ(CS8, static_cast<int>(t.c_cflag & CSIZE));
|
||||
EXPECT_EQ(static_cast<unsigned>(CS8), (t.c_cflag & CSIZE));
|
||||
EXPECT_EQ(1, t.c_cc[VMIN]);
|
||||
EXPECT_EQ(0, t.c_cc[VTIME]);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue