pg_verifybackup: Improve some error handling around strtoul() calls
Three code paths checking the size, timeline ID and system identifier
stored in a manifest now check for an empty value. Values are always
expected in these parts of a backup banifest. A couple of tests are
added to validate this behavior
Additionally, precheck_tar_backup_file() checked that "endptr" is NULL.
Based on the C standard, strtoul() never sets an "endptr" to NULL when
given a value (that is the case here), returning a pointer to the
original value if there is nothing to convert. The pre-tar validation
code is adjusted to do so.
Author: Tristan Partin <tristan@partin.io>
Discussion: https://postgr.es/m/DKBS2Z9CGARC.2T07O6TJYSE8B@partin.io