summaryrefslogtreecommitdiffstats
path: root/ldap/servers/plugins/chainingdb
diff options
context:
space:
mode:
authorRich Megginson <rmeggins@redhat.com>2009-02-16 22:40:13 +0000
committerRich Megginson <rmeggins@redhat.com>2009-02-16 22:40:13 +0000
commitc76c0951a9b66600a07967289fb0cc74c1333865 (patch)
treeca0a22118acd827e88ef27cb23ba2785f5e7a7cf /ldap/servers/plugins/chainingdb
parent90b5a17a3e1c8d26717671086b863779c86a880a (diff)
downloadds-c76c0951a9b66600a07967289fb0cc74c1333865.tar.gz
ds-c76c0951a9b66600a07967289fb0cc74c1333865.tar.xz
ds-c76c0951a9b66600a07967289fb0cc74c1333865.zip
Resolves: bug 481052
Bug Description: some cn=config options show up with incorrect value on 64-bit Reviewed by: nkinder (Thanks!) Fix Description: The get functions return a specific sized type (e.g. an int). We were assigning this to a void *. We cannot do this. We must assign the return value from the get function to the correct size and type variable. I changed the config code to do this. I also had a look at the database and chaining database config code which does similar things with void *, but that code works a little bit differently and appears to be ok. Platforms tested: RHEL5 x86_64 (need to test on HP-UX) Flag Day: no Doc impact: no
Diffstat (limited to 'ldap/servers/plugins/chainingdb')
-rw-r--r--ldap/servers/plugins/chainingdb/cb_instance.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ldap/servers/plugins/chainingdb/cb_instance.c b/ldap/servers/plugins/chainingdb/cb_instance.c
index 19c05bab..f813cec0 100644
--- a/ldap/servers/plugins/chainingdb/cb_instance.c
+++ b/ldap/servers/plugins/chainingdb/cb_instance.c
@@ -1546,7 +1546,7 @@ void cb_instance_config_get(void *arg, cb_instance_config_info *config, char *bu
sprintf(buf, "%o", (int) ((uintptr_t)config->config_get_fn(arg)));
break;
case CB_CONFIG_TYPE_LONG:
- sprintf(buf, "%ld", (long) config->config_get_fn(arg));
+ sprintf(buf, "%ld", (long) ((uintptr_t)config->config_get_fn(arg)));
break;
case CB_CONFIG_TYPE_STRING:
/* Remember the get function for strings returns memory