From 23a6383357990ea8f17fec9af155313d0a186af6 Mon Sep 17 00:00:00 2001 From: Mark Reynolds Date: Jul 22 2013 15:33:03 +0000 Subject: Ticket 47427 - Overflow in nsslapd-disk-monitoring-threshold Bug Description: Using ldapsearch shows threshold value as a negative number, even though the feature is working correctly. Fix Description: When reading the dse, the server was trying to cast the value as a "int". Changed CONFIG_INT to CONFIG_LONG for nsslapd-disk-monioring-threshold. https://fedorahosted.org/389/ticket/47427 Reviewed by: richm(Thanks!) --- diff --git a/ldap/servers/slapd/libglobs.c b/ldap/servers/slapd/libglobs.c index 59879f7..d0380f9 100644 --- a/ldap/servers/slapd/libglobs.c +++ b/ldap/servers/slapd/libglobs.c @@ -679,8 +679,9 @@ static struct config_get_and_set { (ConfigGetFunc)config_get_disk_monitoring}, {CONFIG_DISK_THRESHOLD, config_set_disk_threshold, NULL, 0, - (void**)&global_slapdFrontendConfig.disk_threshold, CONFIG_INT, - (ConfigGetFunc)config_get_disk_threshold}, + (void**)&global_slapdFrontendConfig.disk_threshold, + CONFIG_LONG, (ConfigGetFunc)config_get_disk_threshold, + DEFAULT_DISK_THRESHOLD}, {CONFIG_DISK_GRACE_PERIOD, config_set_disk_grace_period, NULL, 0, (void**)&global_slapdFrontendConfig.disk_grace_period,