posix.cfg: Added support for blkcnt_t datatype.
This commit is contained in:
parent
ee046af20c
commit
ac551807b6
|
@ -446,4 +446,5 @@
|
||||||
<podtype name="pid_t" sign="s"/>
|
<podtype name="pid_t" sign="s"/>
|
||||||
<podtype name="uid_t" sign="u"/>
|
<podtype name="uid_t" sign="u"/>
|
||||||
<podtype name="gid_t" sign="u"/>
|
<podtype name="gid_t" sign="u"/>
|
||||||
|
<podtype name="blkcnt_t" sign="u"/>
|
||||||
</def>
|
</def>
|
||||||
|
|
|
@ -94,6 +94,7 @@ private:
|
||||||
TEST_CASE(stdcfg_tmpnam);
|
TEST_CASE(stdcfg_tmpnam);
|
||||||
|
|
||||||
TEST_CASE(uninitvar_posix_write);
|
TEST_CASE(uninitvar_posix_write);
|
||||||
|
TEST_CASE(uninitvar_posix_types);
|
||||||
|
|
||||||
// dead pointer
|
// dead pointer
|
||||||
TEST_CASE(deadPointer);
|
TEST_CASE(deadPointer);
|
||||||
|
@ -4215,6 +4216,15 @@ private:
|
||||||
"}");
|
"}");
|
||||||
ASSERT_EQUALS("", errout.str());
|
ASSERT_EQUALS("", errout.str());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void uninitvar_posix_types() {
|
||||||
|
checkUninitVarB("blkcnt_t* f() {blkcnt_t *b; return b;}");
|
||||||
|
ASSERT_EQUALS("[test.cpp:1]: (error) Uninitialized variable: b\n", errout.str());
|
||||||
|
|
||||||
|
checkUninitVarB("blkcnt_t f() {blkcnt_t b; return b;}");
|
||||||
|
ASSERT_EQUALS("[test.cpp:1]: (error) Uninitialized variable: b\n", errout.str());
|
||||||
|
;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
REGISTER_TEST(TestUninitVar)
|
REGISTER_TEST(TestUninitVar)
|
||||||
|
|
Loading…
Reference in New Issue