diff options
author | Stefan Metzmacher <metze@samba.org> | 2011-02-02 23:41:17 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2011-02-03 00:33:48 +0100 |
commit | 91e1c8dc383757c3ff0e67c499db4b11242f5800 (patch) | |
tree | dbb38150d57046bdc11b740c4327ed7a1210713e /source3 | |
parent | 40850b3b275494b91b59ebc5e25e11e2235ed722 (diff) | |
download | samba-91e1c8dc383757c3ff0e67c499db4b11242f5800.tar.gz samba-91e1c8dc383757c3ff0e67c499db4b11242f5800.tar.bz2 samba-91e1c8dc383757c3ff0e67c499db4b11242f5800.zip |
s3:lib: allow_trailing_dollar should only allow '$'
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Thu Feb 3 00:33:48 CET 2011 on sn-devel-104
Diffstat (limited to 'source3')
-rw-r--r-- | source3/lib/util_str.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c index 61b46edc5d..fcc4b8d54c 100644 --- a/source3/lib/util_str.c +++ b/source3/lib/util_str.c @@ -820,10 +820,6 @@ void string_sub2(char *s,const char *pattern, const char *insert, size_t len, } for (i=0;i<li;i++) { switch (insert[i]) { - case '`': - case '"': - case '\'': - case ';': case '$': /* allow a trailing $ * (as in machine accounts) */ @@ -831,6 +827,10 @@ void string_sub2(char *s,const char *pattern, const char *insert, size_t len, p[i] = insert[i]; break; } + case '`': + case '"': + case '\'': + case ';': case '%': case '\r': case '\n': @@ -902,16 +902,16 @@ char *realloc_string_sub2(char *string, ld = li - lp; for (i=0;i<li;i++) { switch (in[i]) { - case '`': - case '"': - case '\'': - case ';': case '$': /* allow a trailing $ * (as in machine accounts) */ if (allow_trailing_dollar && (i == li - 1 )) { break; } + case '`': + case '"': + case '\'': + case ';': case '%': case '\r': case '\n': @@ -997,16 +997,16 @@ char *talloc_string_sub2(TALLOC_CTX *mem_ctx, const char *src, for (i=0;i<li;i++) { switch (in[i]) { - case '`': - case '"': - case '\'': - case ';': case '$': /* allow a trailing $ * (as in machine accounts) */ if (allow_trailing_dollar && (i == li - 1 )) { break; } + case '`': + case '"': + case '\'': + case ';': case '%': case '\r': case '\n': |