mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 00:10:10 +01:00
util/disk_cache: Fix cache marker refresh.
Refresh if older than a day, not less than a day old.
Fixes: 3f119a1fd8 ("util/disk_cache: Add marker on cache usage")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29728>
This commit is contained in:
parent
b59ea3d63f
commit
9b775d26c4
1 changed files with 1 additions and 1 deletions
|
|
@ -1077,7 +1077,7 @@ disk_cache_touch_cache_user_marker(char *path)
|
|||
if (fd != -1) {
|
||||
close(fd);
|
||||
}
|
||||
} else if (now - attr.st_mtime < 60 * 60 * 24 /* One day */) {
|
||||
} else if (now - attr.st_mtime > 60 * 60 * 24 /* One day */) {
|
||||
(void)utime(marker_path, NULL);
|
||||
}
|
||||
free(marker_path);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue