From: Ken Raeburn Date: Wed, 5 May 2004 00:47:59 +0000 (+0000) Subject: * threads.c (k5_key_register, destructors, k5_setspecific) [!ENABLE_THREADS]: X-Git-Tag: krb5-1.4-beta1~440 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=46d8093785e68c244db50eaa97fd52592368d001;p=krb5.git * threads.c (k5_key_register, destructors, k5_setspecific) [!ENABLE_THREADS]: Update to fit declarations. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16305 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/util/support/ChangeLog b/src/util/support/ChangeLog index a0f29b27a..a8bd1f57d 100644 --- a/src/util/support/ChangeLog +++ b/src/util/support/ChangeLog @@ -7,3 +7,6 @@ * foreachaddr.c: New file, based on include/foreachaddr.c. * libkrb5support.exports: New file. + * threads.c (k5_key_register, destructors, k5_setspecific) + [!ENABLE_THREADS]: Update to fit declarations. + diff --git a/src/util/support/threads.c b/src/util/support/threads.c index 2aede85e5..e8123ee26 100644 --- a/src/util/support/threads.c +++ b/src/util/support/threads.c @@ -190,7 +190,7 @@ int k5_key_delete (k5_key_t keynum) #else -static void (*destructors[K5_KEY_MAX])(void); +static void (*destructors[K5_KEY_MAX])(void *); static void *tsd_values[K5_KEY_MAX]; static unsigned char destructors_set[K5_KEY_MAX]; @@ -199,12 +199,13 @@ int krb5int_thread_support_init(void) return 0; } -int k5_key_register (k5_key_t keynum, void (*d)(void)) +int k5_key_register (k5_key_t keynum, void (*d)(void *)) { assert(keynum >= 0 && keynum < K5_KEY_MAX); assert(destructors_set[keynum] == 0); destructors[keynum] = d; destructors_set[keynum] = 1; + return 0; } void *k5_getspecific (k5_key_t keynum) @@ -214,7 +215,7 @@ void *k5_getspecific (k5_key_t keynum) return tsd_values[keynum]; } -int k5_setspecific (k5_key_t keynum, const void *value) +int k5_setspecific (k5_key_t keynum, void *value) { assert(keynum >= 0 && keynum < K5_KEY_MAX); assert(destructors_set[keynum] == 1);