[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: C strstr function returns int or char *?



> While compiling:
> 
> char *a = strstr("hello", "ccache=");
> 
> 
> Warning:
> 
> pam_krb5_auth.c:287: warning: initialization makes pointer from integer without a cast

the compiler assumes an int unless you tell it otherwise. make sure you
include <string.h> in the top of the file.

cheers


-- 
Damien <bitwise@repose.cx>                               - eschew obfuscation ;)

Attachment: pgp6OiYS0afOz.pgp
Description: PGP signature


Reply to: