REVERT: add and use der_{malloc,free}
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@22429 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -50,14 +50,14 @@ typedef struct heim_octet_string heim_any_set;
|
||||
#define ASN1_MALLOC_ENCODE(T, B, BL, S, L, R) \
|
||||
do { \
|
||||
(BL) = length_##T((S)); \
|
||||
(B) = der_malloc((BL)); \
|
||||
(B) = malloc((BL)); \
|
||||
if((B) == NULL) { \
|
||||
(R) = ENOMEM; \
|
||||
} else { \
|
||||
(R) = encode_##T(((unsigned char*)(B)) + (BL) - 1, (BL), \
|
||||
(S), (L)); \
|
||||
if((R) != 0) { \
|
||||
der_free((B)); \
|
||||
free((B)); \
|
||||
(B) = NULL; \
|
||||
} \
|
||||
} \
|
||||
|
Reference in New Issue
Block a user