summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2009-11-23 10:30:44 -0500
committerStephen Gallagher <sgallagh@redhat.com>2009-11-23 12:46:29 -0500
commit23341562c1cd4baf46cbc4eacaa09d6b6cb00e82 (patch)
treec609b1c01eaeacf5b9b0160f767eb4a3da434eb3
parenta615676b4f78c4e1f58a511c593c56352580786c (diff)
downloadsssd-23341562c1cd4baf46cbc4eacaa09d6b6cb00e82.tar.gz
sssd-23341562c1cd4baf46cbc4eacaa09d6b6cb00e82.tar.bz2
sssd-23341562c1cd4baf46cbc4eacaa09d6b6cb00e82.zip
Make backend request type a bitfield
-rw-r--r--server/providers/data_provider.h6
-rw-r--r--server/providers/ldap/ldap_id.c2
-rw-r--r--server/providers/proxy.c2
3 files changed, 5 insertions, 5 deletions
diff --git a/server/providers/data_provider.h b/server/providers/data_provider.h
index 1e97d04c..33aed3f2 100644
--- a/server/providers/data_provider.h
+++ b/server/providers/data_provider.h
@@ -70,9 +70,9 @@
#define BE_FILTER_NAME 1
#define BE_FILTER_IDNUM 2
-#define BE_REQ_USER 1
-#define BE_REQ_GROUP 2
-#define BE_REQ_INITGROUPS 3
+#define BE_REQ_USER 0x0001
+#define BE_REQ_GROUP 0x0002
+#define BE_REQ_INITGROUPS 0x0003
/* AUTH related common data and functions */
diff --git a/server/providers/ldap/ldap_id.c b/server/providers/ldap/ldap_id.c
index f99ea7b9..18b387e5 100644
--- a/server/providers/ldap/ldap_id.c
+++ b/server/providers/ldap/ldap_id.c
@@ -628,7 +628,7 @@ void sdap_account_info_handler(struct be_req *breq)
ar = talloc_get_type(breq->req_data, struct be_acct_req);
- switch (ar->entry_type) {
+ switch (ar->entry_type & 0xFFF) {
case BE_REQ_USER: /* user */
/* skip enumerations on demand */
diff --git a/server/providers/proxy.c b/server/providers/proxy.c
index fbd8f162..9cf0c616 100644
--- a/server/providers/proxy.c
+++ b/server/providers/proxy.c
@@ -2065,7 +2065,7 @@ static void proxy_get_account_info(struct be_req *breq)
return proxy_reply(breq, DP_ERR_FATAL, EINVAL, "Invalid attr type");
}
- switch (ar->entry_type) {
+ switch (ar->entry_type & 0xFFF) {
case BE_REQ_USER: /* user */
switch (ar->filter_type) {
case BE_FILTER_NAME: