Changes in uspace/lib/c/test/string.c [7268bf1:06e0f37] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/test/string.c
r7268bf1 r06e0f37 35 35 #pragma GCC diagnostic ignored "-Wstringop-truncation" 36 36 #pragma GCC diagnostic ignored "-Wstringop-overflow" 37 #pragma GCC diagnostic ignored "-Wstringop-overread"38 37 #endif 39 38 … … 800 799 PCUT_TEST(strndup_nonempty_short) 801 800 { 802 #pragma GCC diagnostic push803 // Intentionally checking it works with _longer_ size than actual804 #if defined(__GNUC__) && (__GNUC__ >= 11)805 #pragma GCC diagnostic ignored "-Wstringop-overread"806 #endif807 801 char *d = strndup("abc", 5); 808 #pragma GCC diagnostic pop809 802 PCUT_ASSERT_NOT_NULL(d); 810 803 PCUT_ASSERT_TRUE(d[0] == 'a');
Note:
See TracChangeset
for help on using the changeset viewer.