sssd/FED01-Fix-module-registration-with-newer-LDB-libraries.patch
Stephen Gallagher 3b364490a6 New upstream release 1.5.2
https://fedorahosted.org/sssd/wiki/Releases/Notes-1.5.2
Fixes for support of FreeIPA v2
Fixes for failover if DNS entries change
Improved sss_obfuscate tool with better interactive mode
Fix several crash bugs
Don't attempt to use START_TLS over SSL. Some LDAP servers can't handle this
Delete users from the local cache if initgroups calls return 'no such user'
(previously only worked for getpwnam/getpwuid)
Use new Transifex.net translations
Better support for automatic TGT renewal (now survives restart)
Netgroup fixes
2011-03-10 15:00:40 -05:00

63 lines
1.7 KiB
Diff

From 23e8d84320ae8b76d244764c02e44036e96cd4df Mon Sep 17 00:00:00 2001
From: Stephen Gallagher <sgallagh@redhat.com>
Date: Wed, 9 Feb 2011 15:50:07 -0500
Subject: [PATCH 1/2] Fix module registration with newer LDB libraries.
---
Makefile.am | 1 +
src/ldb_modules/memberof.c | 15 ++++++++++++++-
2 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 49520f3..cc78d04 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -637,6 +637,7 @@ auth_tests_SOURCES = \
$(SSSD_UTIL_OBJ)
auth_tests_CFLAGS = \
$(AM_CFLAGS) \
+ -DSYSDB_TEST \
$(CHECK_CFLAGS)
auth_tests_LDADD = \
$(SSSD_LIBS) \
diff --git a/src/ldb_modules/memberof.c b/src/ldb_modules/memberof.c
index 311e7e5..55c52fd 100644
--- a/src/ldb_modules/memberof.c
+++ b/src/ldb_modules/memberof.c
@@ -1,7 +1,7 @@
/*
SSSD memberof module
- Copyright (C) Simo Sorce <idra@samba.org> 2008
+ Copyright (C) Simo Sorce <idra@samba.org> 2008-2011
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -17,6 +17,11 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+/* Temporary workaround, will be fixed in ldb upstream soon */
+#ifndef LDB_VERSION
+#define LDB_VERSION "0.9.22"
+#endif
+
#include <string.h>
#include "ldb_module.h"
#include "util/util.h"
@@ -3623,3 +3628,11 @@ const struct ldb_module_ops ldb_memberof_module_ops = {
.modify = memberof_mod,
.del = memberof_del,
};
+
+int ldb_init_module(const char *version)
+{
+#ifdef LDB_MODULE_CHECK_VERSION
+ LDB_MODULE_CHECK_VERSION(version);
+#endif
+ return ldb_register_module(&ldb_memberof_module_ops);
+}
--
1.7.4