From: Alec Warner Date: Tue, 14 Mar 2006 15:46:14 +0000 (-0000) Subject: Remove some SystemExit exceptions, make portage behave during a ctrl+c X-Git-Tag: v2.1_pre7~89 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=cf1d6e3132822aa15d724f6b60dabd9a46417e73;p=portage.git Remove some SystemExit exceptions, make portage behave during a ctrl+c svn path=/main/trunk/; revision=2883 --- diff --git a/pym/portage.py b/pym/portage.py index fa7be3660..6e9877565 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -234,10 +234,8 @@ def cacheddir(my_original_path, ignorecvs, ignorelist, EmptyOnError, followSymli if stat.S_ISDIR(pathstat[stat.ST_MODE]): mtime = pathstat[stat.ST_MTIME] else: - raise Exception - except SystemExit, e: - raise - except: + raise portage_exception.PortageException + except (IOError,OSError,portage_exception.PortageException): if EmptyOnError: return [], [] return None, None @@ -262,9 +260,7 @@ def cacheddir(my_original_path, ignorecvs, ignorelist, EmptyOnError, followSymli ftype.append(2) else: ftype.append(3) - except SystemExit, e: - raise - except: + except (IOError, OSError): ftype.append(3) dircache[mypath] = mtime, list, ftype