[6.0] 888b7234e Remove the st_mtime check in vsm_refresh_set

Martin Blix Grydeland martin at varnish-software.com
Fri Oct 18 13:23:07 UTC 2019


commit 888b7234eb5969e1574434e2fd5906064771c104
Author: Martin Blix Grydeland <martin at varnish-software.com>
Date:   Sat Aug 31 12:46:40 2019 +0200

    Remove the st_mtime check in vsm_refresh_set
    
    Now that we incrementally read the file, the check if the mtime of the
    index file has checked has to go away. If not, the index file will always
    be marked as new, forcing a reread of the entire index.

diff --git a/lib/libvarnishapi/vsm.c b/lib/libvarnishapi/vsm.c
index 8f7d469e2..92423ac5b 100644
--- a/lib/libvarnishapi/vsm.c
+++ b/lib/libvarnishapi/vsm.c
@@ -644,8 +644,7 @@ vsm_refresh_set(struct vsm *vd, struct vsm_set *vs)
 	    st.st_dev != vs->fst.st_dev ||
 	    st.st_mode != vs->fst.st_mode ||
 	    st.st_size < vs->fst.st_size ||
-	    st.st_nlink < 1 ||
-	    memcmp(&st.st_mtime, &vs->fst.st_mtime, sizeof st.st_mtime))) {
+	    st.st_nlink < 1)) {
 		closefd(&vs->fd);
 	}
 


More information about the varnish-commit mailing list