libdb: import correct mid file address to db