aboutsummaryrefslogtreecommitdiff
path: root/tests/server/util.h
diff options
context:
space:
mode:
authorMarc Hoersken <info@marc-hoersken.de>2020-04-11 08:35:05 +0200
committerMarc Hoersken <info@marc-hoersken.de>2020-04-12 15:55:21 +0200
commit9869f6dc5af85caf2e0fd4c56713a7f2049ecfff (patch)
tree3b7cd826bd29b5b2fa1ce75a8791926a37c8122c /tests/server/util.h
parentb9a0804ad1abfb6107f411bc6e256522703b40cf (diff)
tests/server: move all signal handling routines to util.[ch]
Avoid code duplication to prepare for portability enhancements.
Diffstat (limited to 'tests/server/util.h')
-rw-r--r--tests/server/util.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/server/util.h b/tests/server/util.h
index 0ae61aee5..0446b6a84 100644
--- a/tests/server/util.h
+++ b/tests/server/util.h
@@ -66,4 +66,13 @@ void clear_advisor_read_lock(const char *filename);
int strncasecompare(const char *first, const char *second, size_t max);
+/* global variable which if set indicates that the program should finish */
+extern volatile int got_exit_signal;
+
+/* global variable which if set indicates the first signal handled */
+extern volatile int exit_signal;
+
+void install_signal_handlers(bool keep_sigalrm);
+void restore_signal_handlers(bool keep_sigalrm);
+
#endif /* HEADER_CURL_SERVER_UTIL_H */