Deleted Added
full compact
a_i2d_fp.c (302408) a_i2d_fp.c (326663)
1/* crypto/asn1/a_i2d_fp.c */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved.
4 *
5 * This package is an SSL implementation written
6 * by Eric Young (eay@cryptsoft.com).
7 * The implementation was written so as to conform with Netscapes SSL.
8 *

--- 73 unchanged lines hidden (view full) ---

82
83int ASN1_i2d_bio(i2d_of_void *i2d, BIO *out, unsigned char *x)
84{
85 char *b;
86 unsigned char *p;
87 int i, j = 0, n, ret = 1;
88
89 n = i2d(x, NULL);
1/* crypto/asn1/a_i2d_fp.c */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved.
4 *
5 * This package is an SSL implementation written
6 * by Eric Young (eay@cryptsoft.com).
7 * The implementation was written so as to conform with Netscapes SSL.
8 *

--- 73 unchanged lines hidden (view full) ---

82
83int ASN1_i2d_bio(i2d_of_void *i2d, BIO *out, unsigned char *x)
84{
85 char *b;
86 unsigned char *p;
87 int i, j = 0, n, ret = 1;
88
89 n = i2d(x, NULL);
90 if (n <= 0)
91 return 0;
92
90 b = (char *)OPENSSL_malloc(n);
91 if (b == NULL) {
92 ASN1err(ASN1_F_ASN1_I2D_BIO, ERR_R_MALLOC_FAILURE);
93 return (0);
94 }
95
96 p = (unsigned char *)b;
97 i2d(x, &p);

--- 60 unchanged lines hidden ---
93 b = (char *)OPENSSL_malloc(n);
94 if (b == NULL) {
95 ASN1err(ASN1_F_ASN1_I2D_BIO, ERR_R_MALLOC_FAILURE);
96 return (0);
97 }
98
99 p = (unsigned char *)b;
100 i2d(x, &p);

--- 60 unchanged lines hidden ---