Update of /cvsroot/tmda/tmda/TMDA
In directory sc8-pr-cvs1:/tmp/cvs-serv30217
Modified Files:
Defaults.py
Log Message:
Tidied up my previous change a little. It's less redundant now.
Index: Defaults.py
===================================================================
RCS file: /cvsroot/tmda/tmda/TMDA/Defaults.py,v
retrieving revision 1.160
retrieving revision 1.161
diff -u -r1.160 -r1.161
--- Defaults.py 28 Nov 2002 17:29:27 -0000 1.160
+++ Defaults.py 30 Nov 2002 18:08:38 -0000 1.161
@@ -1396,12 +1396,10 @@
# Read key from CRYPT_KEY_FILE, and then convert it from hex back into
# raw binary. Hex has only 4 bits of entropy per byte as opposed to 8.
-if PENDING_FILE_PERM == 0600:
+try:
CRYPT_KEY = binascii.unhexlify(open(CRYPT_KEY_FILE).read().strip())
-else:
- try:
- CRYPT_KEY = binascii.unhexlify(open(CRYPT_KEY_FILE).read().strip())
- except: pass
+except IOError:
+ if PENDING_FILE_PERM == 0600: raise
###################################
# END of user configurable settings
_______________________________________
tmda-cvs mailing list
http://tmda.net/lists/listinfo/tmda-cvs