summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2000-10-10 05:05:35 +0000
committerAndrew Tridgell <tridge@samba.org>2000-10-10 05:05:35 +0000
commitd2f07bb7656cd46a93bdaac1d77bfa1c412d8c0c (patch)
tree0db8b7f71bfcb3b44e218c3ae12c165ad07fe2f4 /source3
parent96e27b10bfebbf8f577d7e341cdf2740b607bb15 (diff)
downloadsamba-d2f07bb7656cd46a93bdaac1d77bfa1c412d8c0c.tar.gz
samba-d2f07bb7656cd46a93bdaac1d77bfa1c412d8c0c.tar.bz2
samba-d2f07bb7656cd46a93bdaac1d77bfa1c412d8c0c.zip
don't use gets() !
(This used to be commit e4ea0a5975d3539803c78cac2229550a6e89c4b4)
Diffstat (limited to 'source3')
-rw-r--r--source3/utils/smbcontrol.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/utils/smbcontrol.c b/source3/utils/smbcontrol.c
index 306f7ee269..62019d4036 100644
--- a/source3/utils/smbcontrol.c
+++ b/source3/utils/smbcontrol.c
@@ -248,10 +248,10 @@ static BOOL do_command(char *dest, char *msg_name, char *params)
int myargc;
printf("smbcontrol> ");
- if (!gets(temp)) break;
+ if (!fgets(temp, sizeof(temp)-1, stdin)) break;
myargc = 0;
while ((myargc < 3) &&
- (myargv[myargc] = strtok(myargc?NULL:temp," \t"))) {
+ (myargv[myargc] = strtok(myargc?NULL:temp," \t\n"))) {
myargc++;
}
if (!myargc) break;