Fix #64745 hash_pbkdf2 truncation issue

When using hash_pbkdf2 with hex output and 0 length (auto), it incorrectly
truncates the result to 1/2 the expected result.