The new POSIX directory access in the CBM C library comes with a d_blocks field too.

This commit is contained in:
Oliver Schmidt 2013-02-17 01:03:51 +01:00
parent 010d495e03
commit 9970a3631a

View file

@ -66,11 +66,11 @@ cfs_readdir(struct cfs_dir *p, struct cfs_dirent *e)
return -1; return -1;
} }
strncpy(e->name, res->d_name, sizeof(e->name)); strncpy(e->name, res->d_name, sizeof(e->name));
#if defined(__APPLE2__) || defined(__APPLE2ENH__) #if defined(__APPLE2__) || defined(__APPLE2ENH__) || defined(__CBM__)
e->size = res->d_blocks; e->size = res->d_blocks;
#else /* __APPLE2__ || __APPLE2ENH__ */ #else /* __APPLE2__ || __APPLE2ENH__ || __CBM__ */
e->size = 0; e->size = 0;
#endif /* __APPLE2__ || __APPLE2ENH__ */ #endif /* __APPLE2__ || __APPLE2ENH__ || __CBM__ */
return 0; return 0;
} }
/*---------------------------------------------------------------------------*/ /*---------------------------------------------------------------------------*/