blob: 540ba4a63585b5f630b58bd51be2d51d336fe668 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001openldap: set pointer
2
3When the function ldap_pvt_thread_pool_getkey() succeeds, it
4must set the value of *data since the caller may try to use it.
5
6Upstream-Status: pending
7
8Signed-off-by: Joe Slater <jslater@windriver.com>
9
10
11--- a/libraries/libldap_r/thr_stub.c
12+++ b/libraries/libldap_r/thr_stub.c
13@@ -217,6 +217,7 @@ ldap_pvt_thread_pool_unidle ( ldap_pvt_t
14 int ldap_pvt_thread_pool_getkey (
15 void *ctx, void *key, void **data, ldap_pvt_thread_pool_keyfree_t **kfree )
16 {
17+ if (data) *data = NULL; /* avoid problems with uninitialized *data */
18 return(0);
19 }
20