lib/: get[u]long(): Use ATTR_ACCESS() instead of /*@out@*/
Link: <https://splint.org/manual/manual.html#undefined> Cc: Serge Hallyn <serge@hallyn.com> Signed-off-by: Alejandro Colomar <alx@kernel.org>
This commit is contained in:
committed by
Serge Hallyn
parent
9ca6b71e76
commit
561448443f
+1
-1
@@ -21,7 +21,7 @@
|
||||
* It supports decimal, hexadecimal or octal representations.
|
||||
*/
|
||||
int
|
||||
getlong(const char *numstr, /*@out@*/long *result)
|
||||
getlong(const char *numstr, long *result)
|
||||
{
|
||||
char *endptr;
|
||||
long val;
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@
|
||||
* It supports decimal, hexadecimal or octal representations.
|
||||
*/
|
||||
int
|
||||
getulong(const char *numstr, /*@out@*/unsigned long *result)
|
||||
getulong(const char *numstr, unsigned long *result)
|
||||
{
|
||||
char *endptr;
|
||||
unsigned long val;
|
||||
|
||||
+4
-2
@@ -153,7 +153,8 @@ extern int get_gid (const char *gidstr, gid_t *gid);
|
||||
extern /*@only@*//*@null@*/struct group *getgr_nam_gid (/*@null@*/const char *grname);
|
||||
|
||||
/* getlong.c */
|
||||
extern int getlong (const char *numstr, /*@out@*/long *result);
|
||||
ATTR_ACCESS(write_only, 2)
|
||||
extern int getlong(const char *numstr, long *result);
|
||||
|
||||
/* get_pid.c */
|
||||
extern int get_pid (const char *pidstr, pid_t *pid);
|
||||
@@ -172,7 +173,8 @@ extern time_t gettime (void);
|
||||
extern int get_uid (const char *uidstr, uid_t *uid);
|
||||
|
||||
/* getulong.c */
|
||||
extern int getulong (const char *numstr, /*@out@*/unsigned long *result);
|
||||
ATTR_ACCESS(write_only, 2)
|
||||
extern int getulong(const char *numstr, unsigned long *result);
|
||||
|
||||
/* fputsx.c */
|
||||
ATTR_ACCESS(write_only, 1, 2)
|
||||
|
||||
Reference in New Issue
Block a user