declare pointers passed to string functions as nonnull

pull/1/head
Holger Lubitz 2007-08-02 01:02:06 +02:00
parent e3d10ac673
commit 7e8e4f8abd
1 changed files with 24 additions and 24 deletions

View File

@ -17,32 +17,32 @@
#include <stddef.h> #include <stddef.h>
#include <bits/string.h> #include <bits/string.h>
int __pure strnicmp(const char *s1, const char *s2, size_t len); int __pure strnicmp(const char *s1, const char *s2, size_t len) __nonnull;
char * strcpy(char * dest,const char *src); char * strcpy(char * dest,const char *src) __nonnull;
char * strncpy(char * dest,const char *src,size_t count); char * strncpy(char * dest,const char *src,size_t count) __nonnull;
char * strcat(char * dest, const char * src); char * strcat(char * dest, const char * src) __nonnull;
char * strncat(char *dest, const char *src, size_t count); char * strncat(char *dest, const char *src, size_t count) __nonnull;
int __pure strcmp(const char * cs,const char * ct); int __pure strcmp(const char * cs,const char * ct) __nonnull;
int __pure strncmp(const char * cs,const char * ct, int __pure strncmp(const char * cs,const char * ct,
size_t count); size_t count) __nonnull;
char * __pure strchr(const char * s, int c); char * __pure strchr(const char * s, int c) __nonnull;
char * __pure strrchr(const char * s, int c); char * __pure strrchr(const char * s, int c) __nonnull;
size_t __pure strlen(const char * s); size_t __pure strlen(const char * s) __nonnull;
size_t __pure strnlen(const char * s, size_t count); size_t __pure strnlen(const char * s, size_t count) __nonnull;
size_t __pure strspn(const char *s, const char *accept); size_t __pure strspn(const char *s, const char *accept) __nonnull;
size_t __pure strcspn(const char *s, const char *reject); size_t __pure strcspn(const char *s, const char *reject) __nonnull;
char * __pure strpbrk(const char * cs,const char * ct); char * __pure strpbrk(const char * cs,const char * ct) __nonnull;
char * strtok(char * s,const char * ct); char * strtok(char * s,const char * ct) __nonnull;
char * strsep(char **s, const char *ct); char * strsep(char **s, const char *ct) __nonnull;
void * memset(void * s,int c,size_t count); void * memset(void * s,int c,size_t count) __nonnull;
void * memmove(void * dest,const void *src,size_t count); void * memmove(void * dest,const void *src,size_t count) __nonnull;
int __pure memcmp(const void * cs,const void * ct, int __pure memcmp(const void * cs,const void * ct,
size_t count); size_t count) __nonnull;
void * __pure memscan(const void * addr, int c, size_t size); void * __pure memscan(const void * addr, int c, size_t size) __nonnull;
char * __pure strstr(const char * s1,const char * s2); char * __pure strstr(const char * s1,const char * s2) __nonnull;
void * __pure memchr(const void *s, int c, size_t n); void * __pure memchr(const void *s, int c, size_t n) __nonnull;
char * __pure strdup(const char *s); char * __pure strdup(const char *s) __nonnull;
char * __pure strndup(const char *s, size_t n); char * __pure strndup(const char *s, size_t n) __nonnull;
extern const char * strerror ( int errno ); extern const char * strerror ( int errno );