From fbb83e78c0ca90b09e1e9c0a76030f46f419dcaf Mon Sep 17 00:00:00 2001 From: ed Date: Fri, 19 Oct 2012 05:43:38 +0000 Subject: Fix warnings found by -Wmising-variable-declarations. This self-written compiler warning, which is hopefully going to be committed into LLVM sources soon, warns about potentially missing `static' keywords, similar to -Wmissing-prototypes. - bin/pax: Move external declaration of chdname and s_mask into extern.h. - bin/setfacl: Move setfacl.c-specific stuff out of setfacl.h. - sbin/mount_fusefs: Remove char *progname; use getprogname(). - others: add `static' where possible. --- bin/rcp/rcp.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'bin/rcp') diff --git a/bin/rcp/rcp.c b/bin/rcp/rcp.c index 3357705..186dde6 100644 --- a/bin/rcp/rcp.c +++ b/bin/rcp/rcp.c @@ -76,12 +76,13 @@ __FBSDID("$FreeBSD$"); #define OPTIONS "46dfprt" -struct passwd *pwd; -u_short port; -uid_t userid; -int errs, rem; -int pflag, iamremote, iamrecursive, targetshouldbedirectory; -int family = PF_UNSPEC; +static struct passwd *pwd; +static u_short port; +static uid_t userid; +static int errs, rem; +int iamremote; +static int pflag, iamrecursive, targetshouldbedirectory; +static int family = PF_UNSPEC; static int argc_copy; static const char **argv_copy; @@ -89,7 +90,7 @@ static const char **argv_copy; static char period[] = "."; #define CMDNEEDS 64 -char cmd[CMDNEEDS]; /* must hold "rcp -r -p -d\0" */ +static char cmd[CMDNEEDS]; /* must hold "rcp -r -p -d\0" */ int response(void); void rsource(char *, struct stat *); -- cgit v1.1