lib/transaction_package_replace.c: misc optimizations.
bin/xbps-query/ownedby.c: take into account pkgs with no files.