summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuenter Kukkukk <kukks@samba.org>2013-03-12 04:51:03 +0100
committerRichard Sharpe <realrichardsharpe@gmail.com>2013-03-11 21:40:23 -0700
commitb40c4b069a600af86c1f20ee09cbf5052c1552bf (patch)
treeeceda24d131468e1d27c237785a2cac3d4cc6d02
parent389197e7c31e8d6616e6503181c088940ddb5986 (diff)
downloadsamba-b40c4b069a600af86c1f20ee09cbf5052c1552bf.tar.gz
samba-b40c4b069a600af86c1f20ee09cbf5052c1552bf.tar.bz2
samba-b40c4b069a600af86c1f20ee09cbf5052c1552bf.zip
vfstest: fix the "-c" multiple-command option
Signed-off-by: Guenter Kukkukk <kukks@samba.org> Reviewed-by: Richard Sharpe <realrichardsharpe@gmail.com>
-rw-r--r--source3/torture/vfstest.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source3/torture/vfstest.c b/source3/torture/vfstest.c
index 54365e0350..2cec68711d 100644
--- a/source3/torture/vfstest.c
+++ b/source3/torture/vfstest.c
@@ -108,7 +108,12 @@ static char *next_command(TALLOC_CTX *ctx, char **cmdstr)
if (p)
*p = '\0';
command = talloc_strdup(ctx, *cmdstr);
- *cmdstr = p;
+
+ /* Pass back the remaining cmdstring
+ (a trailing delimiter ";" does also work),
+ or NULL at last cmdstring.
+ */
+ *cmdstr = p ? p + 1 : p;
return command;
}