[master] 79797c666 vtc: New feature check no_sanitizer

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Mon May 10 13:14:06 UTC 2021


commit 79797c66666a1d5b6a902bc4a954bce117484c75
Author: Dridi Boukelmoune <dridi.boukelmoune at gmail.com>
Date:   Mon May 10 14:45:10 2021 +0200

    vtc: New feature check no_sanitizer

diff --git a/bin/varnishtest/vtc_misc.c b/bin/varnishtest/vtc_misc.c
index 88c78982d..53e50812f 100644
--- a/bin/varnishtest/vtc_misc.c
+++ b/bin/varnishtest/vtc_misc.c
@@ -420,6 +420,8 @@ ipvx_works(const char *target)
  *        recognized as a macro.
  * persistent_storage
  *        Varnish was built with the deprecated persistent storage.
+ * no_sanitizer
+ *        Varnish was not built with a sanitizer.
  *
  * Be careful with ignore_unknown_macro, because it may cause a test with a
  * misspelled macro to fail silently. You should only need it if you must
@@ -432,6 +434,12 @@ static const unsigned with_persistent_storage = 1;
 static const unsigned with_persistent_storage = 0;
 #endif
 
+#if __SANITIZER
+static const unsigned no_sanitizer = 0;
+#else
+static const unsigned no_sanitizer = 1;
+#endif
+
 void v_matchproto_(cmd_f)
 cmd_feature(CMD_ARGS)
 {
@@ -475,6 +483,7 @@ cmd_feature(CMD_ARGS)
 		FEATURE("user_vcache", getpwnam("vcache") != NULL);
 		FEATURE("group_varnish", getgrnam("varnish") != NULL);
 		FEATURE("persistent_storage", with_persistent_storage);
+		FEATURE("no_sanitizer", no_sanitizer);
 
 		if (!strcmp(*av, "disable_aslr")) {
 			good = 1;


More information about the varnish-commit mailing list