Move new function CRYPTO_strdup to mem_dbg.c because mem.c is excluded in
authorDr. Stephen Henson <steve@openssl.org>
Mon, 24 Nov 2008 17:02:49 +0000 (17:02 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Mon, 24 Nov 2008 17:02:49 +0000 (17:02 +0000)
a fips build.

crypto/mem.c
crypto/mem_dbg.c

index 3d839b9610b09f8034b632bbb2ae256c24850407..00ebaf0b9b5e304b860b4443c07dc2a45837da6b 100644 (file)
@@ -341,14 +341,6 @@ void *CRYPTO_malloc(int num, const char *file, int line)
        return ret;
        }
 
-char *CRYPTO_strdup(const char *str, const char *file, int line)
-       {
-       char *ret = CRYPTO_malloc(strlen(str)+1, file, line);
-
-       strcpy(ret, str);
-       return ret;
-       }
-
 void *CRYPTO_realloc(void *str, int num, const char *file, int line)
        {
        void *ret = NULL;
index 19376a1814562a6b142b2ac45d7a12b1fb08ff16..dfeb08479931bcb434a95f4e27234e564a6ee5da 100644 (file)
@@ -807,3 +807,11 @@ void CRYPTO_malloc_debug_init(void)
                CRYPTO_dbg_pop_info,
                CRYPTO_dbg_remove_all_info);
        }
+
+char *CRYPTO_strdup(const char *str, const char *file, int line)
+       {
+       char *ret = CRYPTO_malloc(strlen(str)+1, file, line);
+
+       strcpy(ret, str);
+       return ret;
+       }