diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-08-04 20:08:35 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:29:17 -0500 |
commit | c847b2afe7f4c979499c20869563439e25f0cb7e (patch) | |
tree | 7cc705a9c65eee219b83073a2d21da5d18eecc2c /source3/client | |
parent | 87165a81d9a9be0b3476c130cb772a8a578f4f94 (diff) | |
download | samba-c847b2afe7f4c979499c20869563439e25f0cb7e.tar.gz samba-c847b2afe7f4c979499c20869563439e25f0cb7e.tar.bz2 samba-c847b2afe7f4c979499c20869563439e25f0cb7e.zip |
r24223: Convert reply_echo to the new API
(This used to be commit 4863ff2899419e791ed0e340821072d004fb1d17)
Diffstat (limited to 'source3/client')
-rw-r--r-- | source3/client/client.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/source3/client/client.c b/source3/client/client.c index ce66e08930..91cf128bc4 100644 --- a/source3/client/client.c +++ b/source3/client/client.c @@ -777,14 +777,16 @@ static int cmd_du(void) static int cmd_echo(void) { + fstring num; pstring data; - if (!next_token_nr(NULL, data, NULL, sizeof(data))) { - d_printf("echo <data>\n"); + if (!next_token_nr(NULL, num, NULL, sizeof(num)) + || !next_token_nr(NULL, data, NULL, sizeof(data))) { + d_printf("echo <num> <data>\n"); return 1; } - if (!cli_echo(cli, (uint8 *)data, strlen(data))) { + if (!cli_echo(cli, atoi(num), (uint8 *)data, strlen(data))) { d_printf("echo failed: %s\n", nt_errstr(cli_get_nt_error(cli))); return 1; @@ -3730,7 +3732,7 @@ static void readline_callback(void) { unsigned char garbage[16]; memset(garbage, 0xf0, sizeof(garbage)); - cli_echo(cli, garbage, sizeof(garbage)); + cli_echo(cli, 1, garbage, sizeof(garbage)); } } |