Blob Blame History Raw
--- a/contrib/mod_auth_otp/t/api/tests.h
+++ b/contrib/mod_auth_otp/t/api/tests.h
@@ -45,10 +45,10 @@ Suite *tests_get_base32_suite(void);
 Suite *tests_get_hotp_suite(void);
 Suite *tests_get_totp_suite(void);
 
-/* Temporary hack/placement for this variable, until we get to testing
- * the Signals API.
+/* Temporary hack/placement (in stubs.c) for this variable,
+ * until we get to testing the Signals API.
  */
-unsigned int recvd_signal_flags;
+extern volatile unsigned int recvd_signal_flags;
 
 extern pool *auth_otp_pool;
 extern int auth_otp_logfd;
--- a/tests/api/stubs.c
+++ b/tests/api/stubs.c
@@ -38,6 +38,8 @@ xaset_t *server_list = NULL;
 
 static cmd_rec *next_cmd = NULL;
 
+volatile unsigned int recvd_signal_flags = 0;
+
 int tests_stubs_set_next_cmd(cmd_rec *cmd) {
   next_cmd = cmd;
   return 0;
--- a/tests/api/tests.h
+++ b/tests/api/tests.h
@@ -80,10 +80,10 @@ Suite *tests_get_misc_suite(void);
 Suite *tests_get_json_suite(void);
 Suite *tests_get_redis_suite(void);
 
-/* Temporary hack/placement for this variable, until we get to testing
- * the Signals API.
+/* Temporary hack/placement (in stubs.c) for this variable,
+ * until we get to testing the Signals API.
  */
-unsigned int recvd_signal_flags;
+extern volatile unsigned int recvd_signal_flags;
 
 extern char ServerType;
 extern int ServerUseReverseDNS;