I noticed that struct bet_info->bet_type is unused.
Instead of removing it, this patch makes sure that the field is set.
It might be helpful during debugging to get the idea of what be_info
index belong to what backend.
e.g. gdb> p be_ctx->be_info
..., {bet_type = BET_ID, bet_ops = 0x7fbb91ea97a0, pvt_bet_data =
0x1ed00e0, mod_name = 0x1ed21b0 "ipa"}, ...
From 4b488875213668d05393efcd1e4fe6c4f448c058 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pavel=20B=C5=99ezina?= <[email protected]>
Date: Thu, 17 Jan 2013 17:33:58 +0100
Subject: [PATCH 1/2] set struct bet_info->bet_type
---
src/providers/data_provider_be.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/providers/data_provider_be.c b/src/providers/data_provider_be.c
index 5208b48cbc4a15a3f8207a70986af3fd360ec581..ec492b8a26a208820657dddb7fccf7ff0fc4bda1 100644
--- a/src/providers/data_provider_be.c
+++ b/src/providers/data_provider_be.c
@@ -2101,6 +2101,7 @@ static int load_backend_module(struct be_ctx *ctx,
char *mod_init_fn_name = NULL;
bet_init_fn_t mod_init_fn = NULL;
+ (*bet_info).bet_type = bet_type;
(*bet_info).mod_name = NULL;
(*bet_info).bet_ops = NULL;
(*bet_info).pvt_bet_data = NULL;
--
1.7.11.7
_______________________________________________
sssd-devel mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/sssd-devel