[x] I performed a cursory search to see if the bug report is relevant, not redundant, nor in conflict with other tickets.
Describe the bug
On a system where the int32 type is defined as long (rather than int), the CF unit tests fail to build with the following error:
/home/joe/code/cfecfs/github/apps/cf/unit-test/cf_codec_tests.c: In function 'Test_CF_CFDP_DecodeHeader':
/home/joe/code/cfecfs/github/apps/cf/unit-test/cf_codec_tests.c:730:5: error: format '%d' expects argument of type 'int', but argument 6 has type 'int32' [-Werror=format=]
UtAssert_True(ret_val == CFE_SUCCESS, "CF_CFDP_DecodeHeader returned %d and should be 0", ret_val);
^
/home/joe/code/cfecfs/github/apps/cf/unit-test/cf_codec_tests.c:748:5: error: format '%d' expects argument of type 'int', but argument 6 has type 'int32' [-Werror=format=]
UtAssert_True(ret_val == CFE_SUCCESS, "CF_CFDP_DecodeHeader returned %d and should be 0", ret_val);
^
/home/joe/code/cfecfs/github/apps/cf/unit-test/cf_codec_tests.c:755:5: error: format '%d' expects argument of type 'int', but argument 6 has type 'int32' [-Werror=format=]
UtAssert_True(ret_val == -1, "CF_CFDP_DecodeHeader returned %d and should be -1", ret_val);
^
/home/joe/code/cfecfs/github/apps/cf/unit-test/cf_codec_tests.c:762:5: error: format '%d' expects argument of type 'int', but argument 6 has type 'int32' [-Werror=format=]
UtAssert_True(ret_val == -1, "CF_CFDP_DecodeHeader returned %d and should be -1", ret_val);
^
To Reproduce
Build on any system where int32 is not equivalent to int
Expected behavior
Should build successfully
System observed on:
RTEMS
Additional context
This is using UtAssert_True - problem would not exist if the UtAssert_INT32_EQ were used as intended.
Reporter Info
Joseph Hickey, Vantage Systems, Inc.
Checklist (Please check before submitting)
Describe the bug On a system where the
int32
type is defined aslong
(rather thanint
), the CF unit tests fail to build with the following error:To Reproduce Build on any system where
int32
is not equivalent toint
Expected behavior Should build successfully
System observed on: RTEMS
Additional context This is using UtAssert_True - problem would not exist if the
UtAssert_INT32_EQ
were used as intended.Reporter Info Joseph Hickey, Vantage Systems, Inc.