summaryrefslogtreecommitdiff
path: root/yaksh/cpp_stdio_evaluator.py
diff options
context:
space:
mode:
authormahesh2017-04-04 13:00:41 +0530
committermahesh2017-04-04 13:00:41 +0530
commita9d7b48b6a5a79bf619500463d89f03e8ca1b7bb (patch)
tree0c0696c6d071efb7569e425f46c3df2cbb63f6f2 /yaksh/cpp_stdio_evaluator.py
parent734ad94d177be8ad400eb6f97e98612ce099e56a (diff)
downloadonline_test-a9d7b48b6a5a79bf619500463d89f03e8ca1b7bb.tar.gz
online_test-a9d7b48b6a5a79bf619500463d89f03e8ca1b7bb.tar.bz2
online_test-a9d7b48b6a5a79bf619500463d89f03e8ca1b7bb.zip
Kills stray processes in code, hook and stdio evaluator
Diffstat (limited to 'yaksh/cpp_stdio_evaluator.py')
-rw-r--r--yaksh/cpp_stdio_evaluator.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/yaksh/cpp_stdio_evaluator.py b/yaksh/cpp_stdio_evaluator.py
index b302fa4..d211bb7 100644
--- a/yaksh/cpp_stdio_evaluator.py
+++ b/yaksh/cpp_stdio_evaluator.py
@@ -82,7 +82,8 @@ class CppStdIOEvaluator(StdIOEvaluator):
shell=True,
stdin=subprocess.PIPE,
stdout=subprocess.PIPE,
- stderr=subprocess.PIPE
+ stderr=subprocess.PIPE,
+ preexec_fn=os.setpgrp
)
success, err = self.evaluate_stdio(self.user_answer, proc,
self.expected_input,