diff --git a/fsw/src/cf_cfdp.c b/fsw/src/cf_cfdp.c index 4196a4dbd..24ed0a28f 100644 --- a/fsw/src/cf_cfdp.c +++ b/fsw/src/cf_cfdp.c @@ -1921,6 +1921,8 @@ void CF_CFDP_DisableEngine(void) static const CF_QueueIdx_t CLOSE_QUEUES[] = {CF_QueueIdx_RX, CF_QueueIdx_TXA, CF_QueueIdx_TXW}; CF_Channel_t *c; + CF_AppData.engine.enabled = 0; + for (i = 0; i < CF_NUM_CHANNELS; ++i) { c = &CF_AppData.engine.channels[i]; diff --git a/unit-test/cf_cfdp_tests.c b/unit-test/cf_cfdp_tests.c index 7925ceb9f..242fceff0 100644 --- a/unit-test/cf_cfdp_tests.c +++ b/unit-test/cf_cfdp_tests.c @@ -1351,8 +1351,10 @@ void Test_CF_CFDP_DisableEngine(void) */ /* nominal call */ + CF_AppData.engine.enabled = 1; UtAssert_VOIDCALL(CF_CFDP_DisableEngine()); UtAssert_STUB_COUNT(CFE_SB_DeletePipe, CF_NUM_CHANNELS); + UtAssert_BOOL_FALSE(CF_AppData.engine.enabled); /* nominal call with playbacks and polls active */ CF_AppData.engine.channels[UT_CFDP_CHANNEL].playback[0].busy = 1;