summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-11-22 19:26:56 +0000
committerLuke Leighton <lkcl@samba.org>1999-11-22 19:26:56 +0000
commitbb876dc6c3b6b5f1a89524e97bfafd97237bf0ca (patch)
tree04ca35c7fe881cad47e2e4a93259fb7192558f3d
parent48a4df7dac6e076bee0a1de9540108676792377b (diff)
downloadsamba-bb876dc6c3b6b5f1a89524e97bfafd97237bf0ca.tar.gz
samba-bb876dc6c3b6b5f1a89524e97bfafd97237bf0ca.tar.bz2
samba-bb876dc6c3b6b5f1a89524e97bfafd97237bf0ca.zip
another one
(This used to be commit c1ba1bfd68fa96937decad8f1d7421daad6e30fe)
-rw-r--r--source3/rpcclient/cmd_srvsvc.c30
1 files changed, 12 insertions, 18 deletions
diff --git a/source3/rpcclient/cmd_srvsvc.c b/source3/rpcclient/cmd_srvsvc.c
index ca2a8f4dc3..ee67cc7421 100644
--- a/source3/rpcclient/cmd_srvsvc.c
+++ b/source3/rpcclient/cmd_srvsvc.c
@@ -77,13 +77,12 @@ void cmd_srv_query_info(struct client_info *info, int argc, char *argv[])
{
uint32 info_level = 101;
SRV_INFO_CTR ctr;
- fstring tmp;
bzero(&ctr, sizeof(ctr));
- if (next_token(NULL, tmp, NULL, sizeof(tmp)-1))
+ if (argc > 1)
{
- info_level = (uint32)strtol(tmp, (char**)NULL, 10);
+ info_level = (uint32)strtol(argv[1], (char**)NULL, 10);
}
DEBUG(5, ("cmd_srv_query_info: smb_cli->fd:%d\n", smb_cli->fd));
@@ -152,7 +151,6 @@ server enum transports
void cmd_srv_enum_tprt(struct client_info *info, int argc, char *argv[])
{
fstring dest_srv;
- fstring tmp;
SRV_TPRT_INFO_CTR ctr;
uint32 info_level = 0;
@@ -162,9 +160,9 @@ void cmd_srv_enum_tprt(struct client_info *info, int argc, char *argv[])
fstrcat(dest_srv, info->dest_host);
strupper(dest_srv);
- if (next_token(NULL, tmp, NULL, sizeof(tmp)-1))
+ if (argc > 1)
{
- info_level = (uint32)strtol(tmp, (char**)NULL, 10);
+ info_level = (uint32)strtol(argv[1], (char**)NULL, 10);
}
DEBUG(4,("cmd_srv_enum_tprt: server:%s info level: %d\n",
@@ -186,7 +184,6 @@ void cmd_srv_enum_conn(struct client_info *info, int argc, char *argv[])
uint16 fnum;
fstring dest_srv;
fstring qual_srv;
- fstring tmp;
SRV_CONN_INFO_CTR ctr;
ENUM_HND hnd;
uint32 info_level = 0;
@@ -203,9 +200,9 @@ void cmd_srv_enum_conn(struct client_info *info, int argc, char *argv[])
fstrcat(dest_srv, info->dest_host);
strupper(dest_srv);
- if (next_token(NULL, tmp, NULL, sizeof(tmp)-1))
+ if (argc > 1)
{
- info_level = (uint32)strtol(tmp, (char**)NULL, 10);
+ info_level = (uint32)strtol(argv[1], (char**)NULL, 10);
}
DEBUG(4,("cmd_srv_enum_conn: server:%s info level: %d\n",
@@ -251,7 +248,6 @@ void cmd_srv_enum_shares(struct client_info *info, int argc, char *argv[])
{
uint16 fnum;
fstring dest_srv;
- fstring tmp;
SRV_SHARE_INFO_CTR ctr;
ENUM_HND hnd;
uint32 info_level = 1;
@@ -264,9 +260,9 @@ void cmd_srv_enum_shares(struct client_info *info, int argc, char *argv[])
fstrcat(dest_srv, info->dest_host);
strupper(dest_srv);
- if (next_token(NULL, tmp, NULL, sizeof(tmp)-1))
+ if (argc > 1)
{
- info_level = (uint32)strtol(tmp, (char**)NULL, 10);
+ info_level = (uint32)strtol(argv[1], (char**)NULL, 10);
}
DEBUG(4,("cmd_srv_enum_shares: server:%s info level: %d\n",
@@ -312,7 +308,6 @@ void cmd_srv_enum_sess(struct client_info *info, int argc, char *argv[])
{
uint16 fnum;
fstring dest_srv;
- fstring tmp;
SRV_SESS_INFO_CTR ctr;
ENUM_HND hnd;
uint32 info_level = 0;
@@ -325,9 +320,9 @@ void cmd_srv_enum_sess(struct client_info *info, int argc, char *argv[])
fstrcat(dest_srv, info->dest_host);
strupper(dest_srv);
- if (next_token(NULL, tmp, NULL, sizeof(tmp)-1))
+ if (argc > 1)
{
- info_level = (uint32)strtol(tmp, (char**)NULL, 10);
+ info_level = (uint32)strtol(argv[1], (char**)NULL, 10);
}
DEBUG(4,("cmd_srv_enum_sess: server:%s info level: %d\n",
@@ -372,7 +367,6 @@ void cmd_srv_enum_files(struct client_info *info, int argc, char *argv[])
{
uint16 fnum;
fstring dest_srv;
- fstring tmp;
SRV_FILE_INFO_CTR ctr;
ENUM_HND hnd;
uint32 info_level = 3;
@@ -385,9 +379,9 @@ void cmd_srv_enum_files(struct client_info *info, int argc, char *argv[])
fstrcat(dest_srv, info->dest_host);
strupper(dest_srv);
- if (next_token(NULL, tmp, NULL, sizeof(tmp)-1))
+ if (argc > 1)
{
- info_level = (uint32)strtol(tmp, (char**)NULL, 10);
+ info_level = (uint32)strtol(argv[1], (char**)NULL, 10);
}
DEBUG(4,("cmd_srv_enum_files: server:%s info level: %d\n",