summaryrefslogtreecommitdiffstats
path: root/source/smbd/mangle.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2005-06-22 21:20:41 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 10:57:59 -0500
commite9b8d23d6138d909a65ea70b2e801881e8333b38 (patch)
treeef7f5133684b02982ed5cc3c24ff4140be6c887c /source/smbd/mangle.c
parente04fd56e0097dc8007394bf295b227b454e524b4 (diff)
downloadsamba-e9b8d23d6138d909a65ea70b2e801881e8333b38.tar.gz
samba-e9b8d23d6138d909a65ea70b2e801881e8333b38.tar.xz
samba-e9b8d23d6138d909a65ea70b2e801881e8333b38.zip
r7842: With the patch I sent Steve yesterday this gives us complete POSIX pathnames.
ie. files containing : and \ can be accessed from Linux. Jeremy.
Diffstat (limited to 'source/smbd/mangle.c')
-rw-r--r--source/smbd/mangle.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/source/smbd/mangle.c b/source/smbd/mangle.c
index afc1ca12f05..ed69a6210e8 100644
--- a/source/smbd/mangle.c
+++ b/source/smbd/mangle.c
@@ -29,6 +29,7 @@ static const struct {
} mangle_backends[] = {
{ "hash", mangle_hash_init },
{ "hash2", mangle_hash2_init },
+ { "posix", posix_mangle_init },
/*{ "tdb", mangle_tdb_init }, */
{ NULL, NULL }
};
@@ -39,7 +40,7 @@ static const struct {
static void mangle_init(void)
{
int i;
- char *method;
+ const char *method;
if (mangle_fns)
return;
@@ -70,6 +71,13 @@ void mangle_reset_cache(void)
mangle_fns->reset();
}
+void mangle_change_to_posix(void)
+{
+ mangle_fns = NULL;
+ lp_set_mangling_method("posix");
+ mangle_reset_cache();
+}
+
/*
see if a filename has come out of our mangling code
*/