>From 5bc6e6b77afd198fcbdb6acc8191240fc3e81c77 Mon Sep 17 00:00:00 2001
From: Nils Goroll <[email protected]>
Date: Sun, 12 Jul 2015 22:45:07 +0200
Subject: [PATCH 1/2] Add a feature to always keep the vsm file
---
bin/varnishd/mgt/mgt_child.c | 2 +-
include/tbl/feature_bits.h | 4 ++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/bin/varnishd/mgt/mgt_child.c b/bin/varnishd/mgt/mgt_child.c
index 450ec9c..3d55ef6 100644
--- a/bin/varnishd/mgt/mgt_child.c
+++ b/bin/varnishd/mgt/mgt_child.c
@@ -528,7 +528,7 @@ mgt_reap_child(void)
mgt_SHM_Destroy(1);
VSC_C_mgt->child_panic = ++static_VSC_C_mgt.child_panic;
} else {
- mgt_SHM_Destroy(0);
+ mgt_SHM_Destroy(MGT_FEATURE(FEATURE_VSM_KEEP));
}
mgt_SHM_Create();
mgt_SHM_Commit();
diff --git a/include/tbl/feature_bits.h b/include/tbl/feature_bits.h
index 6fcf279..bf4ab7f 100644
--- a/include/tbl/feature_bits.h
+++ b/include/tbl/feature_bits.h
@@ -59,4 +59,8 @@ FEATURE_BIT(ESI_REMOVE_BOM, esi_remove_bom,
"Remove UTF-8 BOM from front of object."
"Ignore and remove the UTF-8 BOM (0xeb 0xbb 0xbf) from front of object."
)
+FEATURE_BIT(VSM_KEEP, vsm_keep,
+ "VSM Keep",
+ "Always keep the VSM file when varnish restarts, not only upon panic."
+)
/*lint -restore */
--
2.1.4
_______________________________________________
varnish-dev mailing list
[email protected]
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-dev