if pkgdb_release_lock is done on a NULL db then return happily