From 5473d529f69810bbb8f275779a188b47bdbd2002 Mon Sep 17 00:00:00 2001
From: Marcus Müller <marcus@hostalia.de>
Date: Mon, 5 Feb 2018 12:00:02 +0100
Subject: modtool_add: __exit__ now takes 4 arguments, instead of none

Python defines __exit__ to take 4 arguments (self + error info); code
only took 1, whih breaks if there is an exception thrown within the
with: block.

Addresses #1577.
---
 gr-utils/python/modtool/util_functions.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'gr-utils/python/modtool/util_functions.py')

diff --git a/gr-utils/python/modtool/util_functions.py b/gr-utils/python/modtool/util_functions.py
index 6bb95f3d67..b20970175c 100644
--- a/gr-utils/python/modtool/util_functions.py
+++ b/gr-utils/python/modtool/util_functions.py
@@ -1,5 +1,5 @@
 #
-# Copyright 2013 Free Software Foundation, Inc.
+# Copyright 2013, 2018 Free Software Foundation, Inc.
 #
 # This file is part of GNU Radio
 #
@@ -169,5 +169,5 @@ class SequenceCompleter(object):
         readline.set_completer(self.completefunc)
         readline.parse_and_bind("tab: complete")
 
-    def __exit__(self):
+    def __exit__(self, exception_type, exception_value, traceback):
         readline.set_completer(self._old_completer)
-- 
cgit v1.2.3