Hi Andrey,
Thanks for v2. It covers both points.
I tested it on master (81b2179b492) with --with-ssl=openssl. The
pgcrypto tests pass in UTF8, LATIN1 and SQL_ASCII databases (crypt-utf8
runs in the first and is skipped in the others). Without the pgcrypto.c
change, all three cases (DES, xDES and MD5) return a hash instead
of the error, so the test catches the bug.
Looks good to me. I'm marking it Ready for Committer.
Thanks,
Ishjaap Singh