You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The CFE_ES_ReloadApp function uses the function OS_stat to perform its work. The error handling in CFE_ES_ReloadApp assumes any failure in OS_stat is due to a file IO issue. This may not be the case because if a null pointer is passed in as the file name OS_stat will return an OS_INVALID_POINTER, but this specific error code will be ignored and CFE_ES_ReloadApp will just output CFE_ES_FILE_IO_ERR instead of a CFE_ES_BAD_ARGUMENT.
To Reproduce
Steps to reproduce the behavior:
Call CFE_ES_ReloadApp with a null pointer for filename. It will return a CFE_ES_FILE_IO_ERR when the real issue was a bad argument.
Expected behavior
CFE_ES_ReloadApp could include a null check itself to provide a more specific error message or the OS_INVALID_POINTER returned by OS_stat could be converted to a specific CFE error code.
Additional context
See #1672 for a similar error conversion issue
Reporter Info
Niall Mullane - GSFC 582 Intern
The text was updated successfully, but these errors were encountered:
Describe the bug
The CFE_ES_ReloadApp function uses the function OS_stat to perform its work. The error handling in CFE_ES_ReloadApp assumes any failure in OS_stat is due to a file IO issue. This may not be the case because if a null pointer is passed in as the file name OS_stat will return an OS_INVALID_POINTER, but this specific error code will be ignored and CFE_ES_ReloadApp will just output CFE_ES_FILE_IO_ERR instead of a CFE_ES_BAD_ARGUMENT.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
CFE_ES_ReloadApp could include a null check itself to provide a more specific error message or the OS_INVALID_POINTER returned by OS_stat could be converted to a specific CFE error code.
Additional context
See #1672 for a similar error conversion issue
Reporter Info
Niall Mullane - GSFC 582 Intern
The text was updated successfully, but these errors were encountered: