summaryrefslogtreecommitdiff
path: root/source3/smbd/mangle.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd/mangle.c')
-rw-r--r--source3/smbd/mangle.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/source3/smbd/mangle.c b/source3/smbd/mangle.c
index 177a34c975..6d98d9e39c 100644
--- a/source3/smbd/mangle.c
+++ b/source3/smbd/mangle.c
@@ -383,13 +383,10 @@ BOOL is_mangled(char *s)
/****************************************************************************
return a base 36 character. v must be from 0 to 35.
****************************************************************************/
-static char base36(int v)
+static char base36(unsigned int v)
{
- v = v % 36;
- if (v < 10)
- return('0'+v);
- else /* needed to work around a DEC C compiler bug */
- return('A' + (v-10));
+ static char basechars[] = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
+ return basechars[v % 36];
}