diff options
author | Michael Adam <obnox@samba.org> | 2008-04-08 22:51:02 +0200 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2008-04-10 01:29:00 +0200 |
commit | e06e8084c6dd33b2d54bd497d245a806a71c5ccc (patch) | |
tree | dae3ce8953a695f821ac69677327d20ce86a1f40 /source3 | |
parent | 7f0127a90347c27a858eac0104e83df858bf5cc1 (diff) | |
download | samba-e06e8084c6dd33b2d54bd497d245a806a71c5ccc.tar.gz samba-e06e8084c6dd33b2d54bd497d245a806a71c5ccc.tar.bz2 samba-e06e8084c6dd33b2d54bd497d245a806a71c5ccc.zip |
libsmbconf: move registry_smbconf_valname_forbidden() to the registry backend
from util_reg.c - no other callers left
Michael
(This used to be commit 98151fd3e1c24e5c8aaf3f5132071e91ac6ef257)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/lib/smbconf/smbconf_reg.c | 22 | ||||
-rw-r--r-- | source3/lib/util_reg.c | 22 |
2 files changed, 22 insertions, 22 deletions
diff --git a/source3/lib/smbconf/smbconf_reg.c b/source3/lib/smbconf/smbconf_reg.c index dada8eece0..e8ce1f55a5 100644 --- a/source3/lib/smbconf/smbconf_reg.c +++ b/source3/lib/smbconf/smbconf_reg.c @@ -41,6 +41,28 @@ static struct reg_private_data *rpd(struct smbconf_ctx *ctx) return (struct reg_private_data *)(ctx->data); } +/* + * check whether a given value name is forbidden in registry (smbconf) + */ +bool registry_smbconf_valname_forbidden(const char *valname) +{ + /* hard code the list of forbidden names here for now */ + const char *forbidden_valnames[] = { + "lock directory", + "lock dir", + "config backend", + NULL + }; + const char **forbidden = NULL; + + for (forbidden = forbidden_valnames; *forbidden != NULL; forbidden++) { + if (strwicmp(valname, *forbidden) == 0) { + return true; + } + } + return false; +} + /** * Open a registry key specified by "path" */ diff --git a/source3/lib/util_reg.c b/source3/lib/util_reg.c index a2a62973de..7366dcb2a7 100644 --- a/source3/lib/util_reg.c +++ b/source3/lib/util_reg.c @@ -119,25 +119,3 @@ void normalize_dbkey(char *key) string_sub(key, "\\", "/", len+1); strupper_m(key); } - -/* - * check whether a given value name is forbidden in registry (smbconf) - */ -bool registry_smbconf_valname_forbidden(const char *valname) -{ - /* hard code the list of forbidden names here for now */ - const char *forbidden_valnames[] = { - "lock directory", - "lock dir", - "config backend", - NULL - }; - const char **forbidden = NULL; - - for (forbidden = forbidden_valnames; *forbidden != NULL; forbidden++) { - if (strwicmp(valname, *forbidden) == 0) { - return true; - } - } - return false; -} |