From 242d068297b79af46c00a94d0e737c79e908a498 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 23 Sep 1998 00:57:34 +0000 Subject: Fixed up warnings in new client code. Note to coders. If using gcc please use the compiler flags : -Wall -Werror -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual *before* checking anything in to ensure a clean compile. Jeremy. (This used to be commit 1daf424da6c5a346f672121d4b6fe5753250f464) --- source3/client/client.c | 86 ++++++++++++++++++++++++------------------------- 1 file changed, 43 insertions(+), 43 deletions(-) (limited to 'source3/client/client.c') diff --git a/source3/client/client.c b/source3/client/client.c index b9b146fc94..1d3623aef2 100644 --- a/source3/client/client.c +++ b/source3/client/client.c @@ -3267,49 +3267,49 @@ struct char compl_args[2]; /* Completion argument info */ } commands[] = { - {"ls",cmd_dir," list the contents of the current directory",COMPL_REMOTE}, - {"dir",cmd_dir," list the contents of the current directory",COMPL_REMOTE}, - {"du",cmd_du," computes the total size of the current directory",COMPL_REMOTE}, - {"lcd",cmd_lcd,"[directory] change/report the local current working directory",COMPL_LOCAL}, - {"cd",cmd_cd,"[directory] change/report the remote directory",COMPL_REMOTE}, - {"pwd",cmd_pwd,"show current remote directory (same as 'cd' with no args)"}, - {"get",cmd_get," [local name] get a file",COMPL_REMOTE,COMPL_LOCAL}, - {"mget",cmd_mget," get all the matching files",COMPL_REMOTE}, - {"put",cmd_put," [remote name] put a file",COMPL_LOCAL,COMPL_REMOTE}, - {"mput",cmd_mput," put all matching files",COMPL_REMOTE}, - {"rename",cmd_rename," rename some files",COMPL_REMOTE,COMPL_REMOTE}, - {"more",cmd_more," view a remote file with your pager",COMPL_REMOTE}, - {"mask",cmd_select," mask all filenames against this",COMPL_REMOTE}, - {"del",cmd_del," delete all matching files",COMPL_REMOTE}, - {"rm",cmd_del," delete all matching files",COMPL_REMOTE}, - {"mkdir",cmd_mkdir," make a directory"}, - {"md",cmd_mkdir," make a directory"}, - {"rmdir",cmd_rmdir," remove a directory"}, - {"rd",cmd_rmdir," remove a directory"}, - {"pq",cmd_p_queue_4,"enumerate the print queue"}, - {"prompt",cmd_prompt,"toggle prompting for filenames for mget and mput"}, - {"recurse",cmd_recurse,"toggle directory recursion for mget and mput"}, - {"translate",cmd_translate,"toggle text translation for printing"}, - {"lowercase",cmd_lowercase,"toggle lowercasing of filenames for get"}, - {"print",cmd_print," print a file"}, - {"printmode",cmd_printmode," set the print mode"}, - {"queue",cmd_queue,"show the print queue"}, - {"qinfo",cmd_qinfo,"show print queue information"}, - {"cancel",cmd_cancel," cancel a print queue entry"}, - {"quit",cli_send_logout,"logoff the server"}, - {"q",cli_send_logout,"logoff the server"}, - {"exit",cli_send_logout,"logoff the server"}, - {"newer",cmd_newer," only mget files newer than the specified local file",COMPL_LOCAL}, - {"archive",cmd_archive,"\n0=ignore archive bit\n1=only get archive files\n2=only get archive files and reset archive bit\n3=get all files and reset archive bit"}, - {"tar",cmd_tar,"tar [IXbgNan] current directory to/from " }, - {"blocksize",cmd_block,"blocksize (default 20)" }, + {"ls",cmd_dir," list the contents of the current directory",{COMPL_REMOTE,COMPL_NONE}}, + {"dir",cmd_dir," list the contents of the current directory",{COMPL_REMOTE,COMPL_NONE}}, + {"du",cmd_du," computes the total size of the current directory",{COMPL_REMOTE,COMPL_NONE}}, + {"lcd",cmd_lcd,"[directory] change/report the local current working directory",{COMPL_LOCAL,COMPL_NONE}}, + {"cd",cmd_cd,"[directory] change/report the remote directory",{COMPL_REMOTE,COMPL_NONE}}, + {"pwd",cmd_pwd,"show current remote directory (same as 'cd' with no args)",{COMPL_NONE,COMPL_NONE}}, + {"get",cmd_get," [local name] get a file",{COMPL_REMOTE,COMPL_LOCAL}}, + {"mget",cmd_mget," get all the matching files",{COMPL_REMOTE,COMPL_NONE}}, + {"put",cmd_put," [remote name] put a file",{COMPL_LOCAL,COMPL_REMOTE}}, + {"mput",cmd_mput," put all matching files",{COMPL_REMOTE,COMPL_NONE}}, + {"rename",cmd_rename," rename some files",{COMPL_REMOTE,COMPL_REMOTE}}, + {"more",cmd_more," view a remote file with your pager",{COMPL_REMOTE,COMPL_NONE}}, + {"mask",cmd_select," mask all filenames against this",{COMPL_REMOTE,COMPL_NONE}}, + {"del",cmd_del," delete all matching files",{COMPL_REMOTE,COMPL_NONE}}, + {"rm",cmd_del," delete all matching files",{COMPL_REMOTE,COMPL_NONE}}, + {"mkdir",cmd_mkdir," make a directory",{COMPL_NONE,COMPL_NONE}}, + {"md",cmd_mkdir," make a directory",{COMPL_NONE,COMPL_NONE}}, + {"rmdir",cmd_rmdir," remove a directory",{COMPL_NONE,COMPL_NONE}}, + {"rd",cmd_rmdir," remove a directory",{COMPL_NONE,COMPL_NONE}}, + {"pq",cmd_p_queue_4,"enumerate the print queue",{COMPL_NONE,COMPL_NONE}}, + {"prompt",cmd_prompt,"toggle prompting for filenames for mget and mput",{COMPL_NONE,COMPL_NONE}}, + {"recurse",cmd_recurse,"toggle directory recursion for mget and mput",{COMPL_NONE,COMPL_NONE}}, + {"translate",cmd_translate,"toggle text translation for printing",{COMPL_NONE,COMPL_NONE}}, + {"lowercase",cmd_lowercase,"toggle lowercasing of filenames for get",{COMPL_NONE,COMPL_NONE}}, + {"print",cmd_print," print a file",{COMPL_NONE,COMPL_NONE}}, + {"printmode",cmd_printmode," set the print mode",{COMPL_NONE,COMPL_NONE}}, + {"queue",cmd_queue,"show the print queue",{COMPL_NONE,COMPL_NONE}}, + {"qinfo",cmd_qinfo,"show print queue information",{COMPL_NONE,COMPL_NONE}}, + {"cancel",cmd_cancel," cancel a print queue entry",{COMPL_NONE,COMPL_NONE}}, + {"quit",cli_send_logout,"logoff the server",{COMPL_NONE,COMPL_NONE}}, + {"q",cli_send_logout,"logoff the server",{COMPL_NONE,COMPL_NONE}}, + {"exit",cli_send_logout,"logoff the server",{COMPL_NONE,COMPL_NONE}}, + {"newer",cmd_newer," only mget files newer than the specified local file",{COMPL_LOCAL,COMPL_NONE}}, + {"archive",cmd_archive,"\n0=ignore archive bit\n1=only get archive files\n2=only get archive files and reset archive bit\n3=get all files and reset archive bit",{COMPL_NONE,COMPL_NONE}}, + {"tar",cmd_tar,"tar [IXbgNan] current directory to/from ",{COMPL_NONE,COMPL_NONE}}, + {"blocksize",cmd_block,"blocksize (default 20)",{COMPL_NONE,COMPL_NONE}}, {"tarmode",cmd_tarmode, - " tar's behaviour towards archive bits" }, - {"setmode",cmd_setmode,"filename change modes of file",COMPL_REMOTE}, - {"help",cmd_help,"[command] give help on a command"}, - {"?",cmd_help,"[command] give help on a command"}, - {"!",NULL,"run a shell command on the local system"}, - {"",NULL,NULL} + " tar's behaviour towards archive bits",{COMPL_NONE,COMPL_NONE}}, + {"setmode",cmd_setmode,"filename change modes of file",{COMPL_REMOTE,COMPL_NONE}}, + {"help",cmd_help,"[command] give help on a command",{COMPL_NONE,COMPL_NONE}}, + {"?",cmd_help,"[command] give help on a command",{COMPL_NONE,COMPL_NONE}}, + {"!",NULL,"run a shell command on the local system",{COMPL_NONE,COMPL_NONE}}, + {"",NULL,NULL,{COMPL_NONE,COMPL_NONE}} }; @@ -3840,7 +3840,7 @@ static void usage(char *pname) BOOL close_it; pstring spec; char pass[128]; - char *p; + if ((p = getenv("PASSWD_FD")) != NULL) { pstrcpy(spec, "descriptor "); pstrcat(spec, p); -- cgit