util: disable cache if we have no build-id and timestamp is zero
authorTimothy Arceri <tarceri@itsqueeze.com>
Wed, 19 Sep 2018 22:54:32 +0000 (08:54 +1000)
committerTimothy Arceri <tarceri@itsqueeze.com>
Tue, 2 Oct 2018 12:07:55 +0000 (22:07 +1000)
commitea66bfda8801a0f5139c8e4655373117cdd7a1c0
tree919e789f97f8084d904d1f1c8de70995a1f22271
parent0bdf7b1d0fb957f69f2c3518399db17d59c5f183
util: disable cache if we have no build-id and timestamp is zero

Timestamp can be zero for example when Flatpak is used. In this
case just disable the cache rather then segfaulting when
incompatible cache items are loaded.

V2: actually return false when mtime is 0.

Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
src/amd/vulkan/radv_device.c
src/util/disk_cache.h