Fix potential coredump on bad locale value in pg_upgrade.
Fix potential coredump on bad locale value in pg_upgrade.

Thinko in error report (and a typo in the message text, too).  We're
failing anyway, but it would be good to print something useful first.
Noted while reviewing a patch to make pg_upgrade's locale code laxer.

zeroae/postgres-xl,pavanvd/postgres-xl,zeroae/postgres-xl,xinzweb/gpdb,yazun/postgres-xl,yazun/postgres-xl,greenplum-db/gpdb,xinzweb/gpdb,ovr/postgres-xl,ashwinstar/gpdb,greenplum-db/gpdb,50wu/gpdb,lisakowen/gpdb,pavanvd/postgres-xl,oberstet/postgres-xl,pavanvd/postgres-xl,Postgres-XL/Postgres-XL,jmcatamney/gpdb,adam8157/gpdb,greenplum-db/gpdb,adam8157/gpdb,zeroae/postgres-xl,greenplum-db/gpdb,ashwinstar/gpdb,jmcatamney/gpdb,lisakowen/gpdb,yazun/postgres-xl,ovr/postgres-xl,yazun/postgres-xl,50wu/gpdb,jmcatamney/gpdb,lisakowen/gpdb,lisakowen/gpdb,greenplum-db/gpdb,Postgres-XL/Postgres-XL,greenplum-db/gpdb,oberstet/postgres-xl,adam8157/gpdb,jmcatamney/gpdb,jmcatamney/gpdb,ashwinstar/gpdb,50wu/gpdb,50wu/gpdb,oberstet/postgres-xl,techdragon/Postgres-XL,lisakowen/gpdb,lisakowen/gpdb,adam8157/gpdb,xinzweb/gpdb,yazun/postgres-xl,xinzweb/gpdb,adam8157/gpdb,lisakowen/gpdb,50wu/gpdb,adam8157/gpdb,xinzweb/gpdb,ashwinstar/gpdb,jmcatamney/gpdb,50wu/gpdb,zeroae/postgres-xl,Postgres-XL/Postgres-XL,oberstet/postgres-xl,greenplum-db/gpdb,zeroae/postgres-xl,xinzweb/gpdb,ashwinstar/gpdb,pavanvd/postgres-xl,ovr/postgres-xl,adam8157/gpdb,jmcatamney/gpdb,ashwinstar/gpdb,xinzweb/gpdb,50wu/gpdb,jmcatamney/gpdb,pavanvd/postgres-xl,techdragon/Postgres-XL,lisakowen/gpdb,xinzweb/gpdb,techdragon/Postgres-XL,oberstet/postgres-xl,ovr/postgres-xl,techdragon/Postgres-XL,ashwinstar/gpdb,greenplum-db/gpdb,ashwinstar/gpdb,50wu/gpdb,Postgres-XL/Postgres-XL,techdragon/Postgres-XL,adam8157/gpdb,Postgres-XL/Postgres-XL,ovr/postgres-xl