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
clang introduced a new warning (following gcc) for string initialization
to char arrays that do not fit the null terminal.
Introduced here: llvm/llvm-project#137829
Included in LLVM version [LLVM
20.1.4](https://github.com/llvm/llvm-project/releases/tag/llvmorg-20.1.4)+
More detail:
-Wunterminated-string-initialization warns for c string literals that
are written to a buffer too small to include a null terminator. This
warning is also included in -Wextra which is enabled for wasi-libc and
fails compilation due to -Werror.
Possible fixes:
1. deactivate the warning
2. add `__attribute__ ((nonstring))` to the three occurrences where this
is a problem.
Chosen solution: 1.
Since the attribute is not available on older clang versions, it would
trigger another warning there.
(included a small formatting change in the commit - pls ignore)
0 commit comments