diff options
author | Zac Medico <zmedico@gentoo.org> | 2006-04-07 09:23:30 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2006-04-07 09:23:30 +0000 |
commit | b6196a6a054f7008c12ae1be456120a0029bc458 (patch) | |
tree | ed7cb401080a414f38d1ca845c21b097b1b50ec8 | |
parent | 2ebcac9f64f29e85b702b9854e365671cb53586e (diff) | |
download | portage-b6196a6a054f7008c12ae1be456120a0029bc458.tar.gz portage-b6196a6a054f7008c12ae1be456120a0029bc458.tar.bz2 portage-b6196a6a054f7008c12ae1be456120a0029bc458.zip |
Raise exceptions when appropriate in the atomic_ofstream constructor for bug #129098.
svn path=/main/trunk/; revision=3087
-rw-r--r-- | pym/portage_util.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pym/portage_util.py b/pym/portage_util.py index bd35e9a10..46a7d1052 100644 --- a/pym/portage_util.py +++ b/pym/portage_util.py @@ -627,6 +627,8 @@ class atomic_ofstream(file): super(atomic_ofstream, self).__init__(tmp_name, mode=mode, **kargs) return except (OSError, IOError), e: + if canonical_path == filename: + raise writemsg("!!! Failed to open file: '%s'\n" % tmp_name) writemsg("!!! %s\n" % str(e)) |