This is an automated email from the git hooks/post-receive script.
mreynolds pushed a commit to branch 389-ds-base-1.3.6
in repository 389-ds-base.
commit 3535afb40c3f42b1345a53ac83df62760b6cd486
Author: Mark Reynolds <mreynolds(a)redhat.com>
Date: Thu Sep 14 08:32:11 2017 -0400
Ticket 49380 - Crash when adding invalid replication
agreement
Bug Description: If you add a replication agreement with an invalid
"replicaEnabled" value
the server crashes when freeing the replica schedule. This is
because the
schedule never gets allocated before the rror conidtion is hit,
and then
it get dereferenced.
Fix Description: Check for a NULL schedule before trying to destroy it.
https://pagure.io/389-ds-base/issue/49380
Reviewed by: tbordaz(Thanks!)
---
ldap/servers/plugins/replication/repl5_schedule.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/ldap/servers/plugins/replication/repl5_schedule.c
b/ldap/servers/plugins/replication/repl5_schedule.c
index c248264..2dab2ff 100644
--- a/ldap/servers/plugins/replication/repl5_schedule.c
+++ b/ldap/servers/plugins/replication/repl5_schedule.c
@@ -130,6 +130,10 @@ schedule_destroy(Schedule *s)
{
int i;
+ if (s == NULL) {
+ return;
+ }
+
/* unschedule update window event if exists */
unschedule_window_state_change_event (s);
@@ -177,11 +181,15 @@ free_schedule_list(schedule_item **schedule_list)
int
schedule_set(Schedule *sch, Slapi_Attr *attr)
{
- int return_value;
+ int return_value = -1;
schedule_item *si = NULL;
schedule_item *new_schedule_list = NULL;
int valid = 1;
+ if (sch == NULL) {
+ return return_value;
+ }
+
if (NULL != attr)
{
int ind;
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.