git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
dad3c6d
)
Fix bug #6939 - mangling method = hash breaks long filenames.
author
Jeremy Allison
<jra@samba.org>
Fri, 18 Dec 2009 00:21:46 +0000
(16:21 -0800)
committer
Karolin Seeger
<kseeger@samba.org>
Wed, 23 Dec 2009 11:08:03 +0000
(12:08 +0100)
We were returning the wrong sense of the bool. must_mangle()
has to return !NT_STATUS_IS_OK, not NT_STATUS_IS_OK.
Jeremy.
(cherry picked from commit
2f1a66a72a6bd9f3e160b01982171dd66835990e
)
source3/smbd/mangle_hash.c
patch
|
blob
|
history
diff --git
a/source3/smbd/mangle_hash.c
b/source3/smbd/mangle_hash.c
index 96fe4d2cab372e0b0c4eac92037aa0e80394f54c..b582d19109d6c71a7806bc2ada2af62deef08073 100644
(file)
--- a/
source3/smbd/mangle_hash.c
+++ b/
source3/smbd/mangle_hash.c
@@
-612,7
+612,10
@@
static bool must_mangle(const char *name,
}
status = is_valid_name(name_ucs2, False, False);
SAFE_FREE(name_ucs2);
- return NT_STATUS_IS_OK(status);
+ /* We return true if we *must* mangle, so if it's
+ * a valid name (status == OK) then we must return
+ * false. Bug #6939. */
+ return !NT_STATUS_IS_OK(status);
}
/*****************************************************************************