diff options
author | Geoff Thorpe <geoff@openssl.org> | 2000-12-01 20:31:52 +0000 |
---|---|---|
committer | Geoff Thorpe <geoff@openssl.org> | 2000-12-01 20:31:52 +0000 |
commit | 385d81380cb8aa062b9d7e2c678419623c7db484 (patch) | |
tree | f866963b5b03410694d03a37d20695327a72a460 /crypto/txt_db/txt_db.h | |
parent | 862e973b50e56d9510cfebc220cf410d3d5e99bc (diff) | |
download | openssl-385d81380cb8aa062b9d7e2c678419623c7db484.tar.gz |
First step in tidying up the LHASH code. The callback prototypes (and
casts) used in the lhash code are about as horrible and evil as they can
be. For starters, the callback prototypes contain empty parameter lists.
Yuck.
This first change defines clearer prototypes - including "typedef"'d
function pointer types to use as "hash" and "compare" callbacks, as well as
the callbacks passed to the lh_doall and lh_doall_arg iteration functions.
Now at least more explicit (and clear) casting is required in all of the
dependant code - and that should be included in this commit.
The next step will be to hunt down and obliterate some of the function
pointer casting being used when it's not necessary - a particularly evil
variant exists in the implementation of lh_doall.
Diffstat (limited to 'crypto/txt_db/txt_db.h')
-rw-r--r-- | crypto/txt_db/txt_db.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/txt_db/txt_db.h b/crypto/txt_db/txt_db.h index 342533d40d..e530af6605 100644 --- a/crypto/txt_db/txt_db.h +++ b/crypto/txt_db/txt_db.h @@ -96,7 +96,7 @@ TXT_DB *TXT_DB_read(char *in, int num); long TXT_DB_write(char *out, TXT_DB *db); #endif int TXT_DB_create_index(TXT_DB *db,int field,int (*qual)(), - unsigned long (*hash)(),int (*cmp)()); + LHASH_HASH_FN_TYPE hash, LHASH_COMP_FN_TYPE cmp); void TXT_DB_free(TXT_DB *db); char **TXT_DB_get_by_index(TXT_DB *db, int idx, char **value); int TXT_DB_insert(TXT_DB *db,char **value); |