diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2006-06-25 12:35:45 +0000 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2006-06-25 12:35:45 +0000 |
commit | 196c38afa3dc8df7bab3c49b102bdbc9445a60d6 (patch) | |
tree | 389ff704b4dc11485b908f9b5faa3b58d2ee9043 /lib | |
parent | 0a388e0832c884b163af7085d6ae39b4f496daae (diff) | |
download | paxutils-196c38afa3dc8df7bab3c49b102bdbc9445a60d6.tar.gz |
(ST_IS_SPARSE): New macro
Diffstat (limited to 'lib')
-rw-r--r-- | lib/system.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/system.h b/lib/system.h index 32b2c5a..0d7fd9a 100644 --- a/lib/system.h +++ b/lib/system.h @@ -386,9 +386,13 @@ extern int errno; #endif #ifndef ST_NBLOCKSIZE -#define ST_NBLOCKSIZE 512 +# define ST_NBLOCKSIZE 512 #endif +#define ST_IS_SPARSE(st) \ + (ST_NBLOCKS (st) \ + < ((st).st_size / ST_NBLOCKSIZE + ((st).st_size % ST_NBLOCKSIZE != 0))) + /* Declare standard functions. */ #if STDC_HEADERS |