moved prototypes from merge.c to merge.h and added #include "merge.h" for

all tools in the clients dir to fix some compile warnings
This commit is contained in:
hoaxter 2004-10-28 16:43:30 +00:00
parent a5a99b3e22
commit ea98d0548c
16 changed files with 42 additions and 17 deletions

View File

@ -12,6 +12,7 @@
#include "client_def.h" #include "client_def.h"
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "merge.h"
#ifdef STDC_HEADERS #ifdef STDC_HEADERS
#include <stdlib.h> #include <stdlib.h>
#endif #endif

View File

@ -18,6 +18,7 @@
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "my-string.h" #include "my-string.h"
#include "merge.h"
#include "printpro.h" #include "printpro.h"
static int f_cd PROTO1(const char *, p) static int f_cd PROTO1(const char *, p)

View File

@ -15,6 +15,7 @@
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "my-string.h" #include "my-string.h"
#include "merge.h"
#ifdef STDC_HEADERS #ifdef STDC_HEADERS
#include <stdlib.h> #include <stdlib.h>
#endif #endif

View File

@ -45,6 +45,7 @@
#include "client_def.h" #include "client_def.h"
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "merge.h"
#include <stdio.h> #include <stdio.h>
#include <sys/types.h> #include <sys/types.h>
#include <time.h> #include <time.h>

View File

@ -24,6 +24,7 @@
#include <utime.h> #include <utime.h>
#endif #endif
#include "my-string.h" #include "my-string.h"
#include "merge.h"
#if !defined(COMMAND_GRAB) && !defined(COMMAND_GET) #if !defined(COMMAND_GRAB) && !defined(COMMAND_GET)
#error "#define COMMAND_XXX to GET or GRAB when compiling this file" #error "#define COMMAND_XXX to GET or GRAB when compiling this file"

View File

@ -14,6 +14,7 @@
#include "c_extern.h" #include "c_extern.h"
#include <stdio.h> #include <stdio.h>
#include "my-string.h" #include "my-string.h"
#include "merge.h"
#include <pwd.h> #include <pwd.h>
#ifdef HAVE_UNISTD_H #ifdef HAVE_UNISTD_H
#include <unistd.h> #include <unistd.h>

View File

@ -12,6 +12,7 @@
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "ls.h" #include "ls.h"
#include "merge.h"
#ifdef STDC_HEADERS #ifdef STDC_HEADERS
#include <stdlib.h> #include <stdlib.h>
#endif #endif

View File

@ -17,6 +17,7 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
#include "my-string.h" #include "my-string.h"
#include "merge.h"
static int make_dir PROTO1(char *, p) static int make_dir PROTO1(char *, p)
{ {

View File

@ -12,6 +12,7 @@
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "my-string.h" #include "my-string.h"
#include "merge.h"
#ifdef STDC_HEADERS #ifdef STDC_HEADERS
#include <stdlib.h> #include <stdlib.h>
#endif #endif

View File

@ -18,6 +18,7 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
#include "my-string.h" #include "my-string.h"
#include "merge.h"
static int timestamps=0; static int timestamps=0;
static int optletter; static int optletter;

View File

@ -18,6 +18,7 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
#include "my-string.h" #include "my-string.h"
#include "merge.h"
static int remove_it PROTO1(char *, p) static int remove_it PROTO1(char *, p)
{ {

View File

@ -18,6 +18,7 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
#include "my-string.h" #include "my-string.h"
#include "merge.h"
static int remove_it PROTO1(char *, p) static int remove_it PROTO1(char *, p)
{ {

View File

@ -13,6 +13,7 @@
#include "c_extern.h" #include "c_extern.h"
#include "bsd_extern.h" #include "bsd_extern.h"
#include "co_extern.h" #include "co_extern.h"
#include "merge.h"
#ifdef STDC_HEADERS #ifdef STDC_HEADERS
#include <stdlib.h> #include <stdlib.h>
#endif #endif

View File

@ -11,6 +11,7 @@
#include "tweak.h" #include "tweak.h"
#include "client_def.h" #include "client_def.h"
#include "c_extern.h" #include "c_extern.h"
#include "merge.h"
#include <stdio.h> #include <stdio.h>
#ifdef STDC_HEADERS #ifdef STDC_HEADERS
#include <stdlib.h> #include <stdlib.h>

View File

@ -16,23 +16,7 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
#include "my-string.h" #include "my-string.h"
#include "merge.h"
/* prototypes */
int fcatcmd_main PROTO2(int, argc, char **, argv);
int fcdcmd_main PROTO2(int, argc, char **, argv);
int fgetcmd_main PROTO2(int, argc, char **, argv);
int fgrabcmd_main PROTO2(int, argc, char **, argv);
int flscmd_main PROTO2(int, argc, char **, argv);
int fmkdir_main PROTO2(int, argc, char **, argv);
int fprocmd_main PROTO2(int, argc, char **, argv);
int fput_main PROTO2(int, argc, char **, argv);
int frmcmd_main PROTO2(int, argc, char **, argv);
int frmdircmd_main PROTO2(int, argc, char **, argv);
int fver_main PROTO2(int, argc, char **, argv);
int fducmd_main PROTO2(int, argc, char **, argv);
int fhostcmd_main PROTO2(int, argc, char **, argv);
int ffindcmd_main PROTO2(int, argc, char **, argv);
int fstatcmd_main PROTO2(int, argc, char **, argv);
int main PROTO2(int, argc, char **, argv) int main PROTO2(int, argc, char **, argv)
{ {

27
clients/merge.h Normal file
View File

@ -0,0 +1,27 @@
/*********************************************************************\
* Copyright (c) 1992 by Wen-King Su (wen-king@vlsi.cs.caltech.edu) *
* *
* You may copy or modify this file in any manner you wish, provided *
* that this notice is always included, and that you hold the author *
* harmless for any loss or damage resulting from the installation or *
* use of this software. *
\*********************************************************************/
/* spliting the prototypes from merge.c to merge.h */
/* prototypes */
int fcatcmd_main PROTO2(int, argc, char **, argv);
int fcdcmd_main PROTO2(int, argc, char **, argv);
int fgetcmd_main PROTO2(int, argc, char **, argv);
int fgrabcmd_main PROTO2(int, argc, char **, argv);
int flscmd_main PROTO2(int, argc, char **, argv);
int fmkdir_main PROTO2(int, argc, char **, argv);
int fprocmd_main PROTO2(int, argc, char **, argv);
int fput_main PROTO2(int, argc, char **, argv);
int frmcmd_main PROTO2(int, argc, char **, argv);
int frmdircmd_main PROTO2(int, argc, char **, argv);
int fver_main PROTO2(int, argc, char **, argv);
int fducmd_main PROTO2(int, argc, char **, argv);
int fhostcmd_main PROTO2(int, argc, char **, argv);
int ffindcmd_main PROTO2(int, argc, char **, argv);
int fstatcmd_main PROTO2(int, argc, char **, argv);