boringssl/crypto/asn1
David Benjamin 15e4deb165 d2i: don't update input pointer on failure
(Imported from upstream's 728bcd59d3d41e152aead0d15acc51a8958536d3.)

Actually this one was reported by us, but the commit message doesn't
mention this.

This is slightly modified from upstream's version to fix some problems
noticed in import. Specifically one of d2i_X509_AUX's success paths is
bust and d2i_PrivateKey still updates on one error path. Resolve the
latter by changing both it and d2i_AutoPrivateKey to explicitly hit the
error path on ret == NULL. This lets us remove the NULL check in
d2i_AutoPrivateKey.

We'll want to report the problems back upstream.

Change-Id: Ifcfc965ca6d5ec0a08ac154854bd351cafbaba25
Reviewed-on: https://boringssl-review.googlesource.com/5948
Reviewed-by: Adam Langley <agl@google.com>
2015-09-28 22:15:17 +00:00
..
a_bitstr.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_bool.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_bytes.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_d2i_fp.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_dup.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_enum.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_gentm.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_i2d_fp.c Fix the type of ASN1_i2d_bio's last argument. 2015-08-28 22:03:54 +00:00
a_int.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_mbstr.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_object.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_octet.c
a_print.c
a_strnid.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_time.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_type.c Fix ASN1_TYPE_cmp 2015-03-19 19:48:41 +00:00
a_utctm.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
a_utf8.c
asn1_lib.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
asn1_locl.h Move the X509_NAME typedef into x509.h. 2014-10-28 22:38:38 +00:00
asn1_par.c Fix wrong numbers being passed as string lengths 2015-03-19 11:07:45 +00:00
asn_pack.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
bio_asn1.c Remove string.h from base.h. 2015-02-02 19:14:15 +00:00
bio_ndef.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
charmap.pl Tag a number of globals as const. 2015-01-14 21:53:00 +00:00
CMakeLists.txt Move arm_arch.h and fix up lots of include paths. 2015-08-26 01:57:59 +00:00
f_enum.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
f_int.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
f_string.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
t_bitst.c Remove string.h from base.h. 2015-02-02 19:14:15 +00:00
t_pkey.c
tasn_dec.c d2i: don't update input pointer on failure 2015-09-28 22:15:17 +00:00
tasn_enc.c Remove string.h from base.h. 2015-02-02 19:14:15 +00:00
tasn_fre.c Convert reference counts in crypto/ 2015-05-20 19:15:26 +00:00
tasn_new.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
tasn_prn.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
tasn_typ.c Allocate string types directly. 2015-03-19 11:47:52 +00:00
tasn_utl.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00
x_bignum.c Tag a number of globals as const. 2015-01-14 21:53:00 +00:00
x_long.c Remove the func parameter to OPENSSL_PUT_ERROR. 2015-07-16 02:02:37 +00:00