Fix error in Rawhide

GCC reports warning on NULL parameter passed into printf. Pass there a
real value.
This commit is contained in:
Petr Menšík 2019-01-28 00:25:32 +01:00
parent 8957a1414e
commit 1dccccd2bb
2 changed files with 37 additions and 0 deletions

View File

@ -0,0 +1,35 @@
From ef1c4b7833de663549e9520e06e2b9f457b5fbec Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Mon, 28 Jan 2019 00:21:31 +0100
Subject: [PATCH] Use correct dn value
New GCC correctly reports error, NULL is always passed in case of
invalid objectclass.
---
src/ldap_helper.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/ldap_helper.c b/src/ldap_helper.c
index 74c0afe..0f6184d 100644
--- a/src/ldap_helper.c
+++ b/src/ldap_helper.c
@@ -4102,7 +4102,6 @@ syncrepl_update(ldap_instance_t *inst, ldap_entry_t **entryp, int chgtype)
ldap_entry_t *entry = NULL;
dns_name_t *zone_name = NULL;
dns_zone_t *zone_ptr = NULL;
- char *dn = NULL;
isc_taskaction_t action = NULL;
isc_task_t *task = NULL;
isc_boolean_t synchronous;
@@ -4155,7 +4154,7 @@ syncrepl_update(ldap_instance_t *inst, ldap_entry_t **entryp, int chgtype)
else if ((entry->class & LDAP_ENTRYCLASS_RR) != 0)
action = update_record;
else {
- log_error("unsupported objectClass: dn '%s'", dn);
+ log_error("unsupported objectClass: dn '%s'", entry->dn);
result = ISC_R_NOTIMPLEMENTED;
goto cleanup;
}
--
2.20.1

View File

@ -16,6 +16,7 @@ Patch1: 0001-Coverity-fix-REVERSE_INULL-for-pevent-inst.patch
Patch2: 0002-Add-empty-callback-for-getsize.patch
Patch3: 0003-Support-for-BIND-9.11.3.patch
Patch4: 0004-Support-for-BIND-9.11.5.patch
Patch5: 0005-Use-correct-dn-value.patch
BuildRequires: bind-devel >= %{bind_version}, bind-lite-devel >= %{bind_version}, bind-pkcs11-devel >= %{bind_version}
BuildRequires: krb5-devel
@ -38,6 +39,7 @@ off of your LDAP server.
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%build
autoreconf -fiv