From 9bce3070acf81a2890ec7a6c94b97094691b5038 Mon Sep 17 00:00:00 2001 From: "Dr. Stephen Henson" Date: Fri, 11 Jun 1999 22:30:45 +0000 Subject: [PATCH 1/1] Fix to i2d_DSAPublicKey() to return the correct length. Submitted by: Jeon KyoungHo --- CHANGES | 4 ++++ crypto/asn1/i2d_s_pu.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index df27820a49..7e9e420e38 100644 --- a/CHANGES +++ b/CHANGES @@ -4,6 +4,10 @@ Changes between 0.9.3a and 0.9.4 + *) Fix a bug in i2d_DSAPublicKey() which meant it returned the wrong value + for the encoded length. + [Jeon KyoungHo ] + *) Add initial documentation of the X509V3 functions. [Steve Henson] diff --git a/crypto/asn1/i2d_s_pu.c b/crypto/asn1/i2d_s_pu.c index 25b150794a..18f790f746 100644 --- a/crypto/asn1/i2d_s_pu.c +++ b/crypto/asn1/i2d_s_pu.c @@ -123,6 +123,7 @@ int i2d_DSAPublicKey(DSA *a, unsigned char **pp) } Free((char *)bs.data); *pp=p; - return(t); + if(all) return(t); + else return(tot); } #endif -- 2.34.1