summaryrefslogtreecommitdiff
path: root/src/main/CMakeLists.txt
diff options
context:
space:
mode:
authorGereon Kremer <gereon.kremer@cs.rwth-aachen.de>2020-07-13 13:57:41 +0200
committerGitHub <noreply@github.com>2020-07-13 06:57:41 -0500
commitdf642ec7d4eef0e2f994751be53e66201f2b92f9 (patch)
tree9ec55084270252c8e67dd117fd5f57a52a845fba /src/main/CMakeLists.txt
parentc7ec792a2086c5b92c4a96d18f7cedb293712dfd (diff)
Implement --tlimit for windows (#4716)
The new mechanism for --tlimit only works for POSIX compatible systems (that implement setitimer). This PR implements an alternative (though roughly equivalent) approach for windows, based on SetWaitableTimer(). To make this work (without code duplication) we need to call the timeout_handler function from time_limit.cpp as the windows solution employs an asynchronous callback instead of signals. I used the opportunity to rename util.cpp to signal_handlers.cpp (as it really does not do anything else) and reformat the file. As I do not have a windows system at hand, I have not been able to actually test this apart from making sure that it compiles with the mingw setup.
Diffstat (limited to 'src/main/CMakeLists.txt')
-rw-r--r--src/main/CMakeLists.txt3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/CMakeLists.txt b/src/main/CMakeLists.txt
index 723d6346f..4fbb14183 100644
--- a/src/main/CMakeLists.txt
+++ b/src/main/CMakeLists.txt
@@ -6,9 +6,10 @@ set(libmain_src_files
interactive_shell.cpp
interactive_shell.h
main.h
+ signal_handlers.cpp
+ signal_handlers.h
time_limit.cpp
time_limit.h
- util.cpp
)
#-----------------------------------------------------------------------------#
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback