[LTP] [PATCH 1/3] link03: Convert docs to docparse
Petr Vorel
pvorel@suse.cz
Thu Oct 26 01:51:27 CEST 2023
Hi Xu,
Also, while you are at it, could you please fix these warnings?
$ make link03
link03.c: In function ‘main’:
link03.c:104:22: warning: ‘%d’ directive writing between 1 and 10 bytes into a region of size between 1 and 255 [-Wformat-overflow=]
104 | sprintf(lname, "%s%d", fname, i);
| ^~
link03.c:104:19: note: directive argument in the range [1, 2147483646]
104 | sprintf(lname, "%s%d", fname, i);
| ^~~~~~
link03.c:104:4: note: ‘sprintf’ output between 2 and 265 bytes into a destination of size 255
104 | sprintf(lname, "%s%d", fname, i);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
link03.c:123:22: warning: ‘%d’ directive writing between 1 and 10 bytes into a region of size between 1 and 255 [-Wformat-overflow=]
123 | sprintf(lname, "%s%d", fname, i);
| ^~
link03.c:123:19: note: directive argument in the range [1, 2147483646]
123 | sprintf(lname, "%s%d", fname, i);
| ^~~~~~
link03.c:123:4: note: ‘sprintf’ output between 2 and 265 bytes into a destination of size 255
123 | sprintf(lname, "%s%d", fname, i);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
link03.c:138:22: warning: ‘%d’ directive writing between 1 and 10 bytes into a region of size between 1 and 255 [-Wformat-overflow=]
138 | sprintf(lname, "%s%d", fname, i);
| ^~
link03.c:138:19: note: directive argument in the range [1, 2147483646]
138 | sprintf(lname, "%s%d", fname, i);
| ^~~~~~
link03.c:138:4: note: ‘sprintf’ output between 2 and 265 bytes into a destination of size 255
138 | sprintf(lname, "%s%d", fname, i);
$ make check-link03
CHECK testcases/kernel/syscalls/link/link03.c
link03.c:1: WARNING: Missing or malformed SPDX-License-Identifier tag in line 1
link03.c:33: ERROR: do not initialise statics to 0
link03.c:55: ERROR: code indent should use tabs where possible
link03.c:90: ERROR: code indent should use tabs where possible
link03.c:100: ERROR: code indent should use tabs where possible
Thanks!
Kind regards,
Petr
More information about the ltp
mailing list