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