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
I performed a cursory search to see if the bug report is relevant, not redundant, nor in conflict with other tickets.
Describe the bug
I believe these are newly triggered GCC warnings (treated as errors) that are now causing the standard MM Build + Run workflow to fail.
In function ‘strncat’,
inlined from ‘MM_DumpInEventCmd’ at /home/runner/work/MM/MM/apps/mm/fsw/src/mm_dump.c:530:25:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:136:10: error: ‘__builtin___strncat_chk’ specified bound depends on the length of the source argument [-Werror=stringop-overflow=]
136 | return __builtin___strncat_chk (__dest, __src, __len, __bos (__dest));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/runner/work/MM/MM/apps/mm/fsw/src/mm_dump.c: In function ‘MM_DumpInEventCmd’:
/home/runner/work/MM/MM/apps/mm/fsw/src/mm_dump.c:530:25: note: length computed here
530 | strncat(EventString, TempString, strlen(TempString));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/string.h:495,
...
In function ‘strncat’,
inlined from ‘MM_DumpInEventCmd’ at /home/runner/work/MM/MM/apps/mm/fsw/src/mm_dump.c:539:21:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:136:10: error: ‘__builtin___strncat_chk’ specified bound depends on the length of the source argument [-Werror=stringop-overflow=]
136 | return __builtin___strncat_chk (__dest, __src, __len, __bos (__dest));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/runner/work/MM/MM/apps/mm/fsw/src/mm_dump.c: In function ‘MM_DumpInEventCmd’:
/home/runner/work/MM/MM/apps/mm/fsw/src/mm_dump.c:539:21: note: length computed here
539 | strncat(EventString, TempString, strlen(TempString));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
To Reproduce
Run the Build + Run GitHub Action on the current main branch MM source code.
Expected behavior
Build + Run workflow should run without errors.
The code that created this build failure is risky because it does not consider the remaining capacity of "EventString". This can potentially lead to buffer overflow. However, changes were since then added to mm_dump.c specifically to safeguard against bufferflow. These changes can be found here: #69
Closing this issue.
Checklist
Describe the bug
I believe these are newly triggered GCC warnings (treated as errors) that are now causing the standard MM Build + Run workflow to fail.
To Reproduce
Run the Build + Run GitHub Action on the current main branch MM source code.
Expected behavior
Build + Run workflow should run without errors.
Reporter Info
Avi @thnkslprpt
The text was updated successfully, but these errors were encountered: