From 4a961ed6ed1b4409aa7e9856a548290fc630ffba Mon Sep 17 00:00:00 2001 From: Hallvard Furuseth Date: Sun, 12 Jun 2016 08:35:25 +0200 Subject: [PATCH] Catch slapmodify entry setup errors --- servers/slapd/slapmodify.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/servers/slapd/slapmodify.c b/servers/slapd/slapmodify.c index 0954bb21b1..77ab751590 100644 --- a/servers/slapd/slapmodify.c +++ b/servers/slapd/slapmodify.c @@ -285,7 +285,9 @@ slapmodify( int argc, char **argv ) rc = (id == NOID); if ( rc == LDAP_SUCCESS && lr.lr_op != LDAP_REQ_DELETE ) { e_orig = be->be_entry_get( be, id ); - e = entry_dup( e_orig ); + if ( e_orig ) + e = entry_dup( e_orig ); + rc = (e == NULL); } break; } -- 2.39.5