Fix leveldb part of #57.