diff options
author | Garming Sam <garming@catalyst.net.nz> | 2014-02-25 16:58:52 +1300 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2014-05-07 19:49:17 +0200 |
commit | 886e44f159bebe927413c35379949453027f518a (patch) | |
tree | 4473614792e5bfcbe637ebbc92264dc4bf18cb02 /source3/param/loadparm.c | |
parent | 9d90969a37244c5e2ddb90daf5ac439cb33cdbf0 (diff) | |
download | samba-886e44f159bebe927413c35379949453027f518a.tar.gz samba-886e44f159bebe927413c35379949453027f518a.tar.xz samba-886e44f159bebe927413c35379949453027f518a.zip |
param: remove unused get_parametrics_by_service
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Diffstat (limited to 'source3/param/loadparm.c')
-rw-r--r-- | source3/param/loadparm.c | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index 2a3a8cba06..095a25816c 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -1171,57 +1171,6 @@ static bool is_synonym_of(int parm1, int parm2, bool *inverse); * pointer to parametrical option value if it exists or NULL otherwise. Actual * parametrical functions are quite simple */ -static struct parmlist_entry *get_parametrics_by_service(struct loadparm_service *service, const char *type, - const char *option, struct parmlist_entry *global_opts) -{ - char* param_key; - struct parmlist_entry *data; - TALLOC_CTX *mem_ctx = talloc_stackframe(); - - param_key = talloc_asprintf(mem_ctx, "%s:%s", type, option); - if (param_key == NULL) { - DEBUG(0,("asprintf failed!\n")); - TALLOC_FREE(mem_ctx); - return NULL; - } - - /* - * Try to fetch the option from the service. - */ - if (service != NULL) { - data = service->param_opt; - while (data) { - if (strwicmp(data->key, param_key) == 0) { - TALLOC_FREE(mem_ctx); - return data; - } - data = data->next; - } - } - - /* - * Fall back to fetching from the globals. - */ - data = global_opts; - while (data) { - if (strwicmp(data->key, param_key) == 0) { - TALLOC_FREE(mem_ctx); - return data; - } - data = data->next; - } - - - TALLOC_FREE(mem_ctx); - - return NULL; -} - -/* - * This is a helper function for parametrical options support. It returns a - * pointer to parametrical option value if it exists or NULL otherwise. Actual - * parametrical functions are quite simple - */ static struct parmlist_entry *get_parametrics(int snum, const char *type, const char *option) { |