diff options
author | 2002-06-07 03:45:32 +0000 | |
---|---|---|
committer | 2002-06-07 03:45:32 +0000 | |
commit | c58501deba7359712e47f5af5c9ade2b346f1ca5 (patch) | |
tree | f25509caa8be355399625b76c2ee0ec4e0c10390 /lib/libcrypto/asn1/a_bitstr.c | |
parent | Import of xfs from arla-0.35.7 (diff) | |
download | wireguard-openbsd-c58501deba7359712e47f5af5c9ade2b346f1ca5.tar.xz wireguard-openbsd-c58501deba7359712e47f5af5c9ade2b346f1ca5.zip |
Merge OpenSSL 0.9.7-stable-20020605,
correctly autogenerate obj_mac.h
Diffstat (limited to 'lib/libcrypto/asn1/a_bitstr.c')
-rw-r--r-- | lib/libcrypto/asn1/a_bitstr.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/libcrypto/asn1/a_bitstr.c b/lib/libcrypto/asn1/a_bitstr.c index c36817c1ee4..ed0bdfbde1a 100644 --- a/lib/libcrypto/asn1/a_bitstr.c +++ b/lib/libcrypto/asn1/a_bitstr.c @@ -71,8 +71,6 @@ int i2c_ASN1_BIT_STRING(ASN1_BIT_STRING *a, unsigned char **pp) if (a == NULL) return(0); len=a->length; - ret=1+len; - if (pp == NULL) return(ret); if (len > 0) { @@ -100,6 +98,10 @@ int i2c_ASN1_BIT_STRING(ASN1_BIT_STRING *a, unsigned char **pp) } else bits=0; + + ret=1+len; + if (pp == NULL) return(ret); + p= *pp; *(p++)=(unsigned char)bits; |