Fix possible read of freed memory when verifying the signature of a file.