diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2000-04-28 05:21:46 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2000-04-28 05:21:46 +0000 |
commit | 38525483073769f0ba9b605a0ab8251a81960cc4 (patch) | |
tree | 9d653c584e0ac4dafe9bbee32c689aa049c0491e /sys/crypto | |
parent | ec6b97de8bd902082e0e349c0907ffd1c6f42c67 (diff) |
avoid using void * when we are talking about pointers
Diffstat (limited to 'sys/crypto')
-rw-r--r-- | sys/crypto/crypto.c | 14 | ||||
-rw-r--r-- | sys/crypto/crypto.h | 4 |
2 files changed, 9 insertions, 9 deletions
diff --git a/sys/crypto/crypto.c b/sys/crypto/crypto.c index d6a4f4cedc0..fa7dea72bbd 100644 --- a/sys/crypto/crypto.c +++ b/sys/crypto/crypto.c @@ -205,8 +205,9 @@ crypto_get_driverid(void) * supported by the driver. */ int -crypto_register(u_int32_t driverid, int alg, void *newses, void *freeses, - void *process) +crypto_register(u_int32_t driverid, int alg, + int (*newses)(u_int32_t *, struct cryptoini *), + int (*freeses)(u_int64_t), int (*process)(struct cryptop *)) { if ((driverid >= crypto_drivers_num) || (alg <= 0) || (alg > CRYPTO_ALGORITHM_MAX) || (crypto_drivers == NULL)) @@ -222,12 +223,9 @@ crypto_register(u_int32_t driverid, int alg, void *newses, void *freeses, if (crypto_drivers[driverid].cc_process == NULL) { - crypto_drivers[driverid].cc_newsession = - (int (*) (u_int32_t *, struct cryptoini *)) newses; - crypto_drivers[driverid].cc_process = - (int (*) (struct cryptop *)) process; - crypto_drivers[driverid].cc_freesession = - (int (*) (u_int64_t)) freeses; + crypto_drivers[driverid].cc_newsession = newses; + crypto_drivers[driverid].cc_process = process; + crypto_drivers[driverid].cc_freesession = freeses; } return 0; diff --git a/sys/crypto/crypto.h b/sys/crypto/crypto.h index b46433a6029..0b1459fa425 100644 --- a/sys/crypto/crypto.h +++ b/sys/crypto/crypto.h @@ -153,7 +153,9 @@ struct cryptocap extern int crypto_newsession(u_int64_t *, struct cryptoini *); extern int crypto_freesession(u_int64_t); extern int crypto_dispatch(struct cryptop *); -extern int crypto_register(u_int32_t, int, void *, void *, void *); +extern int crypto_register(u_int32_t, int, + int (*)(u_int32_t *, struct cryptoini *), int (*)(u_int64_t), + int (*)(struct cryptop *)); extern int crypto_unregister(u_int32_t, int); extern int32_t crypto_get_driverid(void); |