Fix for bad sorting of object names.
[oweals/openssl.git] / crypto / bio / bio_lib.c
index 00163f21bd35ebc72161f4912901b7ad7749c4dd..d8cb83aaabaf8c592588cfefeba7d48a7dacda8b 100644 (file)
@@ -70,7 +70,7 @@ BIO *BIO_new(BIO_METHOD *method)
        {
        BIO *ret=NULL;
 
-       ret=(BIO *)Malloc(sizeof(BIO));
+       ret=(BIO *)OPENSSL_malloc(sizeof(BIO));
        if (ret == NULL)
                {
                BIOerr(BIO_F_BIO_NEW,ERR_R_MALLOC_FAILURE);
@@ -78,7 +78,7 @@ BIO *BIO_new(BIO_METHOD *method)
                }
        if (!BIO_set(ret,method))
                {
-               Free(ret);
+               OPENSSL_free(ret);
                ret=NULL;
                }
        return(ret);
@@ -133,10 +133,13 @@ int BIO_free(BIO *a)
 
        if ((a->method == NULL) || (a->method->destroy == NULL)) return(1);
        ret=a->method->destroy(a);
-       Free(a);
+       OPENSSL_free(a);
        return(1);
        }
 
+void BIO_vfree(BIO *a)
+    { BIO_free(a); }
+
 int BIO_read(BIO *b, void *out, int outl)
        {
        int i;
@@ -532,3 +535,5 @@ unsigned long BIO_number_written(BIO *bio)
        if(bio) return bio->num_write;
        return 0;
 }
+
+IMPLEMENT_STACK_OF(BIO)