From 6064ab3dbf004ace14b84cf0ce37599317dc68bb Mon Sep 17 00:00:00 2001 From: Marko Kreen Date: Sun, 5 Jun 2016 19:12:23 +0300 Subject: [PATCH] No need for exc_info anymore. --- rarfile.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/rarfile.py b/rarfile.py index 7571c64..373c546 100644 --- a/rarfile.py +++ b/rarfile.py @@ -1900,8 +1900,7 @@ def custom_popen(cmd): p = Popen(cmd, bufsize = 0, stdout = PIPE, stdin = PIPE, stderr = STDOUT, creationflags = creationflags) - except OSError: - ex = sys.exc_info()[1] + except OSError as ex: if ex.errno == errno.ENOENT: raise RarCannotExec("Unrar not installed? (rarfile.UNRAR_TOOL=%r)" % UNRAR_TOOL) raise -- 2.11.4.GIT