summaryrefslogtreecommitdiff
path: root/source4/client
diff options
context:
space:
mode:
Diffstat (limited to 'source4/client')
-rw-r--r--source4/client/client.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source4/client/client.c b/source4/client/client.c
index 748ee2d7cb..65bcfeefb6 100644
--- a/source4/client/client.c
+++ b/source4/client/client.c
@@ -2997,16 +2997,18 @@ static int process_stdin(struct smbclient_context *ctx)
char *the_prompt = talloc_asprintf(ctx, "smb: %s> ", ctx->remote_cur_dir);
char *cline = smb_readline(the_prompt, readline_callback, completion_fn);
talloc_free(the_prompt);
-
+
if (!cline) break;
-
+
/* special case - first char is ! */
if (*cline == '!') {
system(cline + 1);
continue;
}
- rc |= process_command_string(ctx, cline);
+ rc |= process_command_string(ctx, cline);
+ free(cline);
+
}
return rc;