From b86ba124eab06ab9b132647bee4c00c13269e185 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Tue, 28 Apr 1998 15:41:03 +0000 Subject: [PATCH] Support byte-swapped dbhash (bsddb) files. Found by Ben Sayer. --- Lib/whichdb.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/whichdb.py b/Lib/whichdb.py index 3186edf1a78..c072e5bdbe8 100644 --- a/Lib/whichdb.py +++ b/Lib/whichdb.py @@ -50,7 +50,7 @@ def whichdb(filename): return "gdbm" # Check for BSD hash - if magic == 0x061561: + if magic in (0x00061561, 0x61150600): return "dbhash" # Unknown