Commit 6f1a93ad authored by Rich Salz's avatar Rich Salz
Browse files

Dead code removal: #if 0 conf, dso, pqueue, threads



Mostly, but not completely, debugging print statements.
Some old logic kept for internal documentation reasons, perhaps.

Reviewed-by: default avatarRichard Levitte <levitte@openssl.org>
parent 2e635aa8
Loading
Loading
Loading
Loading
+0 −22
Original line number Diff line number Diff line
@@ -157,28 +157,6 @@ char *_CONF_get_string(const CONF *conf, const char *section,
        return (getenv(name));
}

#if 0                           /* There's no way to provide error checking
                                 * with this function, so force implementors
                                 * of the higher levels to get a string and
                                 * read the number themselves. */
long _CONF_get_number(CONF *conf, char *section, char *name)
{
    char *str;
    long ret = 0;

    str = _CONF_get_string(conf, section, name);
    if (str == NULL)
        return (0);
    for (;;) {
        if (conf->meth->is_number(conf, *str))
            ret = ret * 10 + conf->meth->to_int(conf, *str);
        else
            return (ret);
        str++;
    }
}
#endif

static unsigned long conf_value_hash(const CONF_VALUE *v)
{
    return (lh_strhash(v->section) << 2) ^ lh_strhash(v->name);
+0 −16
Original line number Diff line number Diff line
@@ -373,19 +373,3 @@ int NCONF_dump_bio(const CONF *conf, BIO *out)

    return conf->meth->dump(conf, out);
}

/* This function should be avoided */
#if 0
long NCONF_get_number(CONF *conf, char *group, char *name)
{
    int status;
    long ret = 0;

    status = NCONF_get_number_e(conf, group, name, &ret);
    if (status == 0) {
        /* This function does not believe in errors... */
        ERR_get_error();
    }
    return ret;
}
#endif
+0 −12
Original line number Diff line number Diff line
@@ -77,13 +77,6 @@ static int dl_load(DSO *dso);
static int dl_unload(DSO *dso);
static void *dl_bind_var(DSO *dso, const char *symname);
static DSO_FUNC_TYPE dl_bind_func(DSO *dso, const char *symname);
# if 0
static int dl_unbind_var(DSO *dso, char *symname, void *symptr);
static int dl_unbind_func(DSO *dso, char *symname, DSO_FUNC_TYPE symptr);
static int dl_init(DSO *dso);
static int dl_finish(DSO *dso);
static int dl_ctrl(DSO *dso, int cmd, long larg, void *parg);
# endif
static char *dl_name_converter(DSO *dso, const char *filename);
static char *dl_merger(DSO *dso, const char *filespec1,
                       const char *filespec2);
@@ -96,11 +89,6 @@ static DSO_METHOD dso_meth_dl = {
    dl_unload,
    dl_bind_var,
    dl_bind_func,
/* For now, "unbind" doesn't exist */
# if 0
    NULL,                       /* unbind_var */
    NULL,                       /* unbind_func */
# endif
    NULL,                       /* ctrl */
    dl_name_converter,
    dl_merger,
+0 −11
Original line number Diff line number Diff line
@@ -99,12 +99,6 @@ static int dlfcn_load(DSO *dso);
static int dlfcn_unload(DSO *dso);
static void *dlfcn_bind_var(DSO *dso, const char *symname);
static DSO_FUNC_TYPE dlfcn_bind_func(DSO *dso, const char *symname);
# if 0
static int dlfcn_unbind(DSO *dso, char *symname, void *symptr);
static int dlfcn_init(DSO *dso);
static int dlfcn_finish(DSO *dso);
static long dlfcn_ctrl(DSO *dso, int cmd, long larg, void *parg);
# endif
static char *dlfcn_name_converter(DSO *dso, const char *filename);
static char *dlfcn_merger(DSO *dso, const char *filespec1,
                          const char *filespec2);
@@ -117,11 +111,6 @@ static DSO_METHOD dso_meth_dlfcn = {
    dlfcn_unload,
    dlfcn_bind_var,
    dlfcn_bind_func,
/* For now, "unbind" doesn't exist */
# if 0
    NULL,                       /* unbind_var */
    NULL,                       /* unbind_func */
# endif
    NULL,                       /* ctrl */
    dlfcn_name_converter,
    dlfcn_merger,
+0 −5
Original line number Diff line number Diff line
@@ -72,11 +72,6 @@ static DSO_METHOD dso_meth_null = {
    NULL,                       /* unload */
    NULL,                       /* bind_var */
    NULL,                       /* bind_func */
/* For now, "unbind" doesn't exist */
#if 0
    NULL,                       /* unbind_var */
    NULL,                       /* unbind_func */
#endif
    NULL,                       /* ctrl */
    NULL,                       /* dso_name_converter */
    NULL,                       /* dso_merger */
Loading