gcc meet problem with "stat" function
dong
cxd@sti.gd.cn
Fri Apr 28 00:51:00 GMT 2000
hello,I write some codes calling function stat , following
is the codes:
....
#include <sys/stat.h>
....
struct stat sb; u_int32_t tmp;ÃÂ ÃÂ ÃÂ /*
u_int32_t is a 16_bit user_defined variable */
...
ÃÂ
if (stat("./market.dat,&sb))ÃÂ ÃÂ return
(__os_get_errno()); ...
ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ ÃÂ
tmp=(u_int32_t)(sb.st_ino);
ÃÂ
....
ÃÂ
but it gives me messages:
gcc -c -ansiÃÂ os_fid.c os_fid.c: In function
`__os_fileid': os_fid.c:84: aggregate value used where an integer was
expected
having already checked the stat.h and types.h ,I'm still
confused
about this
my system info:
solaris 2.6
SMCgcc 2.95.2
ÃÂ
wish you can help me
ÃÂ
samuel
4/28
More information about the Gcc-help
mailing list