This is another small backport that can only be tested after we have the loadtxoutset RPC command, but that I think should be included before we allow loadng UTXO snapshot because it may guard against amount malleation in snapshot files (see https://github.com/bitcoin/bitcoin/pull/28685#issuecomment-1770720541 "certain negative values seem to result in the same hash as their positive counter part")
This is a partial backport of core#28685
https://github.com/bitcoin/bitcoin/pull/28685/commits/f6213929c519d0e615cacd3d6f479f1517be1662