Describe the bug
The SAMPLE_ProcessCC example calls CFE_TBL_GetAddress() and then immediately proceeds to dereference the pointer, without checking its return code.
To Reproduce
This is primarily evident in unit test, where the CFE_TBL_GetAddress() call can be forced to fail. It outputs a NULL pointer in this case and subsequently segfaults.
Expected behavior
The SAMPLE_ProcessCC() should not attempt to dereference the pointer output of CFE_TBL_GetAddress() unless that function actually returns CFE_SUCCESS
System observed on:
Ubuntu 18.04 LTS 64-bit (when running UT)
Reporter Info
Joseph Hickey, Vantage Systems, Inc.