diff options
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/dso/Makefile.in | 4 | ||||
-rw-r--r-- | crypto/dso/build.info | 2 | ||||
-rw-r--r-- | crypto/dso/dso_dl.c | 11 | ||||
-rw-r--r-- | crypto/dso/dso_dlfcn.c | 11 | ||||
-rw-r--r-- | crypto/dso/dso_locl.h | 1 | ||||
-rw-r--r-- | crypto/dso/dso_null.c | 84 | ||||
-rw-r--r-- | crypto/dso/dso_openssl.c | 21 | ||||
-rw-r--r-- | crypto/dso/dso_vms.c | 11 | ||||
-rw-r--r-- | crypto/dso/dso_win32.c | 11 |
9 files changed, 22 insertions, 134 deletions
diff --git a/crypto/dso/Makefile.in b/crypto/dso/Makefile.in index 8c517febce..e2fec28d4b 100644 --- a/crypto/dso/Makefile.in +++ b/crypto/dso/Makefile.in @@ -15,9 +15,9 @@ CFLAGS= $(INCLUDES) $(CFLAG) $(SHARED_CFLAG) GENERAL=Makefile LIB=$(TOP)/libcrypto.a -LIBSRC= dso_dl.c dso_dlfcn.c dso_err.c dso_lib.c dso_null.c \ +LIBSRC= dso_dl.c dso_dlfcn.c dso_err.c dso_lib.c \ dso_openssl.c dso_win32.c dso_vms.c -LIBOBJ= dso_dl.o dso_dlfcn.o dso_err.o dso_lib.o dso_null.o \ +LIBOBJ= dso_dl.o dso_dlfcn.o dso_err.o dso_lib.o \ dso_openssl.o dso_win32.o dso_vms.o SRC= $(LIBSRC) diff --git a/crypto/dso/build.info b/crypto/dso/build.info index 30b3a280ba..82b592d9a1 100644 --- a/crypto/dso/build.info +++ b/crypto/dso/build.info @@ -1,4 +1,4 @@ LIBS=../../libcrypto SOURCE[../../libcrypto]=\ - dso_dl.c dso_dlfcn.c dso_err.c dso_lib.c dso_null.c \ + dso_dl.c dso_dlfcn.c dso_err.c dso_lib.c \ dso_openssl.c dso_win32.c dso_vms.c diff --git a/crypto/dso/dso_dl.c b/crypto/dso/dso_dl.c index 1d6e12adc5..72ca4544aa 100644 --- a/crypto/dso/dso_dl.c +++ b/crypto/dso/dso_dl.c @@ -58,12 +58,7 @@ #include "dso_locl.h" -#ifndef DSO_DL -DSO_METHOD *DSO_METHOD_dl(void) -{ - return NULL; -} -#else +#ifdef DSO_DL # include <dl.h> @@ -95,9 +90,9 @@ static DSO_METHOD dso_meth_dl = { dl_globallookup }; -DSO_METHOD *DSO_METHOD_dl(void) +DSO_METHOD *DSO_METHOD_openssl(void) { - return (&dso_meth_dl); + return &dso_meth_dl; } /* diff --git a/crypto/dso/dso_dlfcn.c b/crypto/dso/dso_dlfcn.c index e69daadc4c..09a49131ea 100644 --- a/crypto/dso/dso_dlfcn.c +++ b/crypto/dso/dso_dlfcn.c @@ -67,12 +67,7 @@ #include "dso_locl.h" -#ifndef DSO_DLFCN -DSO_METHOD *DSO_METHOD_dlfcn(void) -{ - return NULL; -} -#else +#ifdef DSO_DLFCN # ifdef HAVE_DLFCN_H # ifdef __osf__ @@ -117,9 +112,9 @@ static DSO_METHOD dso_meth_dlfcn = { dlfcn_globallookup }; -DSO_METHOD *DSO_METHOD_dlfcn(void) +DSO_METHOD *DSO_METHOD_openssl(void) { - return (&dso_meth_dlfcn); + return &dso_meth_dlfcn; } /* diff --git a/crypto/dso/dso_locl.h b/crypto/dso/dso_locl.h index 980448d25a..3d7d669d47 100644 --- a/crypto/dso/dso_locl.h +++ b/crypto/dso/dso_locl.h @@ -105,4 +105,3 @@ struct dso_meth_st { /* Perform global symbol lookup, i.e. among *all* modules */ void *(*globallookup) (const char *symname); }; - diff --git a/crypto/dso/dso_null.c b/crypto/dso/dso_null.c deleted file mode 100644 index ed8bcd77ef..0000000000 --- a/crypto/dso/dso_null.c +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Written by Geoff Thorpe (geoff@geoffthorpe.net) for the OpenSSL project - * 2000. - */ -/* ==================================================================== - * Copyright (c) 2000 The OpenSSL Project. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. All advertising materials mentioning features or use of this - * software must display the following acknowledgment: - * "This product includes software developed by the OpenSSL Project - * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)" - * - * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to - * endorse or promote products derived from this software without - * prior written permission. For written permission, please contact - * licensing@OpenSSL.org. - * - * 5. Products derived from this software may not be called "OpenSSL" - * nor may "OpenSSL" appear in their names without prior written - * permission of the OpenSSL Project. - * - * 6. Redistributions of any form whatsoever must retain the following - * acknowledgment: - * "This product includes software developed by the OpenSSL Project - * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)" - * - * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY - * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR - * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT - * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, - * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED - * OF THE POSSIBILITY OF SUCH DAMAGE. - * ==================================================================== - * - * This product includes cryptographic software written by Eric Young - * (eay@cryptsoft.com). This product includes software written by Tim - * Hudson (tjh@cryptsoft.com). - * - */ - -/* - * This "NULL" method is provided as the fallback for systems that have no - * appropriate support for "shared-libraries". - */ - -#include "dso_locl.h" - -static DSO_METHOD dso_meth_null = { - "NULL shared library method", - NULL, /* load */ - NULL, /* unload */ - NULL, /* bind_var */ - NULL, /* bind_func */ - NULL, /* ctrl */ - NULL, /* dso_name_converter */ - NULL, /* dso_merger */ - NULL, /* init */ - NULL, /* finish */ - NULL, /* pathbyaddr */ - NULL /* globallookup */ -}; - -DSO_METHOD *DSO_METHOD_null(void) -{ - return &dso_meth_null; -} diff --git a/crypto/dso/dso_openssl.c b/crypto/dso/dso_openssl.c index 9b0123b29a..070f116217 100644 --- a/crypto/dso/dso_openssl.c +++ b/crypto/dso/dso_openssl.c @@ -58,21 +58,14 @@ #include "dso_locl.h" -/* We just pinch the method from an appropriate "default" method. */ +#if !defined(DSO_VMS) && !defined(DSO_DLCFN) && !defined(DSO_DL) && !defined(DSO_WIN32) && !defined(DSO_DLFCN) + +static DSO_METHOD dso_meth_null = { + "NULL shared library method" +}; DSO_METHOD *DSO_METHOD_openssl(void) { -#ifdef DEF_DSO_METHOD - return (DEF_DSO_METHOD()); -#elif defined(DSO_DLFCN) - return (DSO_METHOD_dlfcn()); -#elif defined(DSO_DL) - return (DSO_METHOD_dl()); -#elif defined(DSO_WIN32) - return (DSO_METHOD_win32()); -#elif defined(DSO_VMS) - return (DSO_METHOD_vms()); -#else - return (DSO_METHOD_null()); -#endif + return dso_meth_null(); } +#endif diff --git a/crypto/dso/dso_vms.c b/crypto/dso/dso_vms.c index 2fd6ffea2d..79e9963a26 100644 --- a/crypto/dso/dso_vms.c +++ b/crypto/dso/dso_vms.c @@ -58,12 +58,7 @@ #include "dso_locl.h" -#ifndef OPENSSL_SYS_VMS -DSO_METHOD *DSO_METHOD_vms(void) -{ - return NULL; -} -#else +#ifdef OPENSSL_SYS_VMS # pragma message disable DOLLARID # include <errno.h> @@ -129,9 +124,9 @@ typedef struct dso_internal_st { char imagename[NAMX_MAXRSS + 1]; } DSO_VMS_INTERNAL; -DSO_METHOD *DSO_METHOD_vms(void) +DSO_METHOD *DSO_METHOD_openssl(void) { - return (&dso_meth_vms); + return &dso_meth_vms; } static int vms_load(DSO *dso) diff --git a/crypto/dso/dso_win32.c b/crypto/dso/dso_win32.c index e1d88b1d5e..e378d68946 100644 --- a/crypto/dso/dso_win32.c +++ b/crypto/dso/dso_win32.c @@ -58,12 +58,7 @@ #include "dso_locl.h" -#if !defined(DSO_WIN32) -DSO_METHOD *DSO_METHOD_win32(void) -{ - return NULL; -} -#else +#if defined(DSO_WIN32) # ifdef _WIN32_WCE # if _WIN32_WCE < 300 @@ -138,9 +133,9 @@ static DSO_METHOD dso_meth_win32 = { win32_globallookup }; -DSO_METHOD *DSO_METHOD_win32(void) +DSO_METHOD *DSO_METHOD_openssl(void) { - return (&dso_meth_win32); + return &dso_meth_win32; } /* |