[Fedora-directory-commits] ldapserver/ldap/servers/plugins/chainingdb cb_instance.c, 1.14, 1.15
Richard Allen Megginson
rmeggins at fedoraproject.org
Mon Feb 16 22:40:15 UTC 2009
Author: rmeggins
Update of /cvs/dirsec/ldapserver/ldap/servers/plugins/chainingdb
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv32539/ldapserver/ldap/servers/plugins/chainingdb
Modified Files:
cb_instance.c
Log Message:
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
Index: cb_instance.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/plugins/chainingdb/cb_instance.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- cb_instance.c 27 Jan 2009 22:37:17 -0000 1.14
+++ cb_instance.c 16 Feb 2009 22:40:13 -0000 1.15
@@ -1546,7 +1546,7 @@
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
More information about the Fedora-directory-commits
mailing list