flatpak (and ostree) report an st_mtime of 0 (or 1 in past versions) for all files it controls, which does not match the real time recorded when installing the plugins in the mock buildroot. Therefore, check this only when it appears to be real.epel10
parent
db2b332ca1
commit
a3d726f79e
@ -0,0 +1,23 @@
|
||||
Based on the Flathub patch but only skip the mtime test when in an ostree
|
||||
(different versions have used 0 or 1 as the mtime for all files).
|
||||
|
||||
https://github.com/flathub/org.videolan.VLC/blob/master/vlc-ignore-time-for-cache.patch
|
||||
|
||||
diff --git a/src/modules/bank.c b/src/modules/bank.c
|
||||
index 2e67a0d07e..ab2915fbb7 100644
|
||||
--- a/src/modules/bank.c
|
||||
+++ b/src/modules/bank.c
|
||||
@@ -275,7 +275,8 @@ static int AllocatePluginFile (module_bank_t *bank, const char *abspath,
|
||||
plugin = vlc_cache_lookup(&bank->cache, relpath);
|
||||
|
||||
if (plugin != NULL
|
||||
- && (plugin->mtime != (int64_t)st->st_mtime
|
||||
+ && (((int64_t)st->st_mtime > (int64_t)1
|
||||
+ && plugin->mtime != (int64_t)st->st_mtime)
|
||||
|| plugin->size != (uint64_t)st->st_size))
|
||||
{
|
||||
msg_Err(bank->obj, "stale plugins cache: modified %s",
|
||||
plugin->abspath);
|
||||
--
|
||||
2.21.0
|
||||
|
Loading…
Reference in new issue