This is the mail archive of the cygwin-developers@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

cygwin_stat_lite


Hi!

  In order to allow porter to speed up stat and lstat functions. When
application calls stat or lstat, it rarely needs all information
fields of struct stat. In the same time, getting st_ino or st_nlink in
cygwin are quite time-consuming operations, especially for files on
remote drive. So, it'd be nice to allow appliction programmer or
porter to point out, which fields of struct stat he really needs. It
could be done with cygwin_stat_lite and cygwin_lstat_lite functions by
passing them an appropriate bitmask.

==========================================================================
#define STAT_LITE_TIME  0x0001
#define STAT_LITE_INODE 0x0002
#define STAT_LITE_PERM  0x0004
#define STAT_LITE_NLINK 0x0008
#define STAT_LITE_OWNER 0x0010
#define STAT_LITE_SIZE  0x0020
#define STAT_LITE_ALL   0x003F

extern int cygwin_stat_lite (char *, struct stat*, unsigned long flags) ;
extern int cygwin_lstat_lite (char *, struct stat*, unsigned long flags) ;
==========================================================================

Egor.            mailto:deo@logos-m.ru ICQ 5165414 FidoNet 2:5020/496.19

stat_lite.diff.gz


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]