From 3bb31d1888d0b07025a6095dd128349c4633012b Mon Sep 17 00:00:00 2001 From: Noriko Hosoi Date: Mon, 10 Feb 2014 17:53:45 -0800 Subject: [PATCH 162/225] Ticket #47693 - Environment variables are not passed when DS is started via service Description: The previous commit 57199b34c9cbe4a703e537633fbe6beab9a94e81 contained a cherry-pick error. Replaced CFG_ONOFF_LOCK_WRITE with CFG_LOCK_WRITE, and CFG_ONOFF_UNLOCK_WRITE with CFG_UNLOCK_WRITE (cherry picked from commit 98986b513ed0cf243fe43ce0e745828da680208f) --- ldap/servers/slapd/libglobs.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ldap/servers/slapd/libglobs.c b/ldap/servers/slapd/libglobs.c index 903d38b..8103133 100644 --- a/ldap/servers/slapd/libglobs.c +++ b/ldap/servers/slapd/libglobs.c @@ -6676,9 +6676,9 @@ config_set_malloc_mxfast(const char *attrname, char *value, char *errorbuf, int value, CONFIG_MALLOC_MXFAST, max); return LDAP_OPERATIONS_ERROR; } - CFG_ONOFF_LOCK_WRITE(slapdFrontendConfig); + CFG_LOCK_WRITE(slapdFrontendConfig); slapdFrontendConfig->malloc_mxfast = mxfast; - CFG_ONOFF_UNLOCK_WRITE(slapdFrontendConfig); + CFG_UNLOCK_WRITE(slapdFrontendConfig); if ((mxfast >= 0) && (mxfast <= max)) { mallopt(M_MXFAST, mxfast); @@ -6719,9 +6719,9 @@ config_set_malloc_trim_threshold(const char *attrname, char *value, char *errorb return LDAP_OPERATIONS_ERROR; } - CFG_ONOFF_LOCK_WRITE(slapdFrontendConfig); + CFG_LOCK_WRITE(slapdFrontendConfig); slapdFrontendConfig->malloc_trim_threshold = trim_threshold; - CFG_ONOFF_UNLOCK_WRITE(slapdFrontendConfig); + CFG_UNLOCK_WRITE(slapdFrontendConfig); if (trim_threshold >= -1) { mallopt(M_TRIM_THRESHOLD, trim_threshold); @@ -6769,9 +6769,9 @@ config_set_malloc_mmap_threshold(const char *attrname, char *value, char *errorb return LDAP_OPERATIONS_ERROR; } - CFG_ONOFF_LOCK_WRITE(slapdFrontendConfig); + CFG_LOCK_WRITE(slapdFrontendConfig); slapdFrontendConfig->malloc_mmap_threshold = mmap_threshold; - CFG_ONOFF_UNLOCK_WRITE(slapdFrontendConfig); + CFG_UNLOCK_WRITE(slapdFrontendConfig); if ((mmap_threshold >= 0) && (mmap_threshold <= max)) { mallopt(M_MMAP_THRESHOLD, mmap_threshold); -- 1.8.1.4