SeattleTestbed / attic

ARCHIVAL: Full mirror of SeattleTestbed's SVN in early 2014. We use GitHub since!
MIT License
0 stars 1 forks source link

seash_helper doesn't properly catch "file not found" on delete #1382

Closed choksi81 closed 10 years ago

choksi81 commented 10 years ago

r7081 introduced a new helper function to seash_helper.py which is required when generating new user keys for which key files do already exist (among other things). These files are deleted before the new keys are saved. In its current form, the function won't detect the error that arises when the file it should delete doesn't exist in the first place.

My patch is trivial, I'm replacing the check for a magic string ("cannot find the file") that neither Linux nor Mac OS X produced in my tests with a check for the OSError's errno instead. Please review and commit!

choksi81 commented 10 years ago

Attachments: https://github.com/SeattleTestbed/attic/blob/master/TICKET_ATTACHMENTS/seash_helper.diff