From 4539128ffcbc7459b4a6a759b9654edf5312b4e3 Mon Sep 17 00:00:00 2001 From: Tim Burke Date: Tue, 14 Jul 2020 12:52:10 -0700 Subject: [PATCH] py3: Fix sigint handler Change-Id: I46c196c389f9425c398506a4abe4dd0abed7ade9 --- swiftbench/bench.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/swiftbench/bench.py b/swiftbench/bench.py index 976c03a..8acce2d 100644 --- a/swiftbench/bench.py +++ b/swiftbench/bench.py @@ -386,9 +386,10 @@ class BenchController(object): def sigint1(self, signum, frame): if self.delete: - print >>sys.stderr, ( + print( 'SIGINT received; finishing up and running DELETE.\n' - 'Send one more SIGINT to exit *immediately*.') + 'Send one more SIGINT to exit *immediately*.', + file=sys.stderr) self.aborted = True if self.running and not isinstance(self.running, BenchDELETE): self.running.aborted = True