diff options
Diffstat (limited to 'data.c')
| -rw-r--r-- | data.c | 13 |
1 files changed, 13 insertions, 0 deletions
| @@ -249,6 +249,19 @@ double mtime_nl(const char *fn, int *n_link) | |||
| 249 | } | 249 | } |
| 250 | 250 | ||
| 251 | 251 | ||
| 252 | double f_ctime(const char *fn) | ||
| 253 | /* returns the ctime of a file or directory, or 0.0 */ | ||
| 254 | { | ||
| 255 | struct stat st; | ||
| 256 | double r = 0.0; | ||
| 257 | |||
| 258 | if (fn && stat(fn, &st) != -1) | ||
| 259 | r = (double) st.st_ctim.tv_sec; | ||
| 260 | |||
| 261 | return r; | ||
| 262 | } | ||
| 263 | |||
| 264 | |||
| 252 | /** database 2.1+ **/ | 265 | /** database 2.1+ **/ |
| 253 | 266 | ||
| 254 | /** indexes **/ | 267 | /** indexes **/ |