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