summaryrefslogtreecommitdiff
path: root/yaksh/bash_stdio_evaluator.py
diff options
context:
space:
mode:
authorPrabhu Ramachandran2017-04-27 17:28:44 +0530
committerGitHub2017-04-27 17:28:44 +0530
commita67f8597da19527669b596fab08083a18c7e1fcc (patch)
tree26484d05a23223df13aabb42fe674ce759e09187 /yaksh/bash_stdio_evaluator.py
parentea9e60c47b763515b324aa507da06a1e91c488c6 (diff)
parent4a8f9a117f6a784fe722b8b381368c41be86024a (diff)
downloadonline_test-a67f8597da19527669b596fab08083a18c7e1fcc.tar.gz
online_test-a67f8597da19527669b596fab08083a18c7e1fcc.tar.bz2
online_test-a67f8597da19527669b596fab08083a18c7e1fcc.zip
Merge pull request #274 from maheshgudi/kill_stray_processes
Kill stray processes
Diffstat (limited to 'yaksh/bash_stdio_evaluator.py')
-rw-r--r--yaksh/bash_stdio_evaluator.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/yaksh/bash_stdio_evaluator.py b/yaksh/bash_stdio_evaluator.py
index 334620d..1ce729a 100644
--- a/yaksh/bash_stdio_evaluator.py
+++ b/yaksh/bash_stdio_evaluator.py
@@ -49,7 +49,8 @@ class BashStdIOEvaluator(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,