cregistry: If ROLLBACK fails with SQLITE_BUSY, it will always do so
cregistry: If ROLLBACK fails with SQLITE_BUSY, it will always do so

See http://www.sqlite.org/lang_transaction.html, section
"The ROLLBACK will fail with an error code SQLITE_BUSY ..."
Since MacPorts is single-threaded, nobody can/will finalize the pending queries,
causing this to become an endless loop, if rollback fails.

Also finalize another query early so we have no open queries during updating the
database.

git-svn-id: 620571fa9b4bd0cbce9a0cf901e91ef896adbf27@88983 d073be05-634f-4543-b044-5fe20cf6d1d6

danchr/macports-base,neverpanic/macports-base,macports/macports-base,macports/macports-base,danchr/macports-base,neverpanic/macports-base