Blame SOURCES/0046-ldap-fix-modifytimestamp-debugging-leftovers.patch

f55c47
From fff02bbf7967d291ccb019fae741e6591ed8fd41 Mon Sep 17 00:00:00 2001
f55c47
From: =?UTF-8?q?Pavel=20B=C5=99ezina?= <pbrezina@redhat.com>
f55c47
Date: Fri, 12 Feb 2021 15:30:59 +0100
f55c47
Subject: [PATCH] ldap: fix modifytimestamp debugging leftovers
f55c47
f55c47
---
f55c47
 src/providers/ldap/sdap.c | 4 ++--
f55c47
 1 file changed, 2 insertions(+), 2 deletions(-)
f55c47
f55c47
diff --git a/src/providers/ldap/sdap.c b/src/providers/ldap/sdap.c
f55c47
index c853e4dc1..32c0144b9 100644
f55c47
--- a/src/providers/ldap/sdap.c
f55c47
+++ b/src/providers/ldap/sdap.c
f55c47
@@ -1391,7 +1391,7 @@ int sdap_get_server_opts_from_rootdse(TALLOC_CTX *memctx,
f55c47
     last_usn_name = opts->gen_map[SDAP_AT_LAST_USN].name;
f55c47
     entry_usn_name = opts->gen_map[SDAP_AT_ENTRY_USN].name;
f55c47
     if (rootdse) {
f55c47
-        if (false) {
f55c47
+        if (last_usn_name) {
f55c47
             ret = sysdb_attrs_get_string(rootdse,
f55c47
                                           last_usn_name, &last_usn_value);
f55c47
             if (ret != EOK) {
f55c47
@@ -1500,7 +1500,7 @@ int sdap_get_server_opts_from_rootdse(TALLOC_CTX *memctx,
f55c47
         }
f55c47
     }
f55c47
 
f55c47
-    if (true) {
f55c47
+    if (!last_usn_name) {
f55c47
         DEBUG(SSSDBG_FUNC_DATA,
f55c47
               "No known USN scheme is supported by this server!\n");
f55c47
         if (!entry_usn_name) {
f55c47
-- 
f55c47
2.21.3
f55c47