Preserve errors to get the correct exception
Preserve errors to get the correct exception

During the switch to BoringSSL, agl noticed the error state wasn't being
preserved correctly. Integrate part of the BoringSSL change to preserve
error states.

Bug: 18388980
Change-Id: I9a6fea4f3bf457808a337604290c6bfd1b9ea84e

google/conscrypt,google/conscrypt,google/conscrypt,google/conscrypt,google/conscrypt,google/conscrypt