Skip to content

Commit

Permalink
Fix #753, Remove UT_CheckForOpenSockets
Browse files Browse the repository at this point in the history
  • Loading branch information
skliper committed Jan 11, 2021
1 parent 81c4fa8 commit c968de0
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 29 deletions.
23 changes: 0 additions & 23 deletions src/ut-stubs/utstub-helpers.c
Original file line number Diff line number Diff line change
Expand Up @@ -184,26 +184,3 @@ void UT_ObjIdDecompose(osal_id_t id, uint32 *indx, UT_ObjType_t *objtype)
*indx = idv & 0xFFFFUL;
*objtype = (idv >> 16) ^ 0x4000UL;
}

/*
** Report and close any sockets found open
** Moved here temporarily to ensure full compatibility with CFE implementation
**
** NOTE - this historically only checked for queues that were created but not
** cleaned up. Although the current impl could check for anything, only queues
** are done for now.
*/
void UT_CheckForOpenSockets(void)
{
UT_ObjTypeState_t *StatePtr;
uint32 i;

StatePtr = &UT_ObjState[UT_OBJTYPE_QUEUE];
for (i = 0; i <= StatePtr->LastIssueNumber; ++i)
{
if ((StatePtr->ValidBits[i >> 3] & (1 << (i & 0x07))) != 0)
{
UtAssert_Failed("UT_Queue %d left open.\n", (int)i);
}
}
}
6 changes: 0 additions & 6 deletions src/ut-stubs/utstub-helpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -107,12 +107,6 @@ osal_id_t UT_AllocStubObjId(UT_ObjType_t ObjType);
*/
void UT_DeleteStubObjId(UT_ObjType_t ObjType, osal_id_t ObjId);

/*
* Helper function - Report any queue objects found open
* (for compatibility with CFE tests, only checks queues)
*/
void UT_CheckForOpenSockets(void);

/*
* Helper function - Clear all OSAL UT stub objects
* Resets the stub object table back to its initial/empty state
Expand Down

0 comments on commit c968de0

Please sign in to comment.