Fix to the db_open_local() function in the case where the root directory is writable by the current user.