| 353 | } |
| 354 | |
| 355 | static int is_racy_stat(const struct index_state *istate, |
| 356 | const struct stat_data *sd) |
| 357 | { |
| 358 | return (istate->timestamp.sec && |
| 359 | #ifdef USE_NSEC |
| 360 | /* nanosecond timestamped files can also be racy! */ |
| 361 | (istate->timestamp.sec < sd->sd_mtime.sec || |
| 362 | (istate->timestamp.sec == sd->sd_mtime.sec && |
| 363 | istate->timestamp.nsec <= sd->sd_mtime.nsec)) |
| 364 | #else |
| 365 | istate->timestamp.sec <= sd->sd_mtime.sec |
| 366 | #endif |
| 367 | ); |
| 368 | } |
| 369 | |
| 370 | int is_racy_timestamp(const struct index_state *istate, |
| 371 | const struct cache_entry *ce) |
no outgoing calls
no test coverage detected