Fix some problems found in dbtest_4.