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
When compiling `code = {0x00}` with GCC 12 -O3 it detects a false
positive buffer overflow and gives a warning. Workaround it by using
explicit `code = bytes{0x00}`.
```
/usr/include/c++/12/bits/char_traits.h:268:23: error: ‘void* __builtin_memcpy(void*, const void*, long unsigned int)’ accessing 9223372036854775810 or more bytes at offsets -4611686018427387902 and [-4611686018427387903, 4611686018427387904] may overlap up to 9223372036854775813 bytes at offset -3 [-Werror=restrict]
268 | __builtin_memcpy(__s1, __s2, __n * sizeof(char_type));
| ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```
The warning is gone in GCC 13.
0 commit comments