diff options
author | Ed Schouten <ed@FreeBSD.org> | 2012-10-19 05:43:38 +0000 |
---|---|---|
committer | Ed Schouten <ed@FreeBSD.org> | 2012-10-19 05:43:38 +0000 |
commit | ae824d80f28cd14c0c0ec75076c796e6a369bc18 (patch) | |
tree | 4ffbcf3b1f945e0ae5715cc8c2500ff622b14872 /libexec | |
parent | 8241616dc534f6cf0c95abe6b61bc2bb0378fc91 (diff) | |
download | src-ae824d80f28cd14c0c0ec75076c796e6a369bc18.tar.gz src-ae824d80f28cd14c0c0ec75076c796e6a369bc18.zip |
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.
Notes
Notes:
svn path=/head/; revision=241720
Diffstat (limited to 'libexec')
-rw-r--r-- | libexec/tftpd/tftp-io.c | 4 | ||||
-rw-r--r-- | libexec/tftpd/tftp-utils.c | 2 | ||||
-rw-r--r-- | libexec/tftpd/tftpd.c | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/libexec/tftpd/tftp-io.c b/libexec/tftpd/tftp-io.c index 3ce4f6ef44e7..d5d7fc6401fc 100644 --- a/libexec/tftpd/tftp-io.c +++ b/libexec/tftpd/tftp-io.c @@ -53,7 +53,7 @@ struct sockaddr_storage me_sock; static int send_packet(int peer, uint16_t block, char *pkt, int size); -struct errmsg { +static struct errmsg { int e_code; const char *e_msg; } errmsgs[] = { @@ -375,7 +375,7 @@ send_data(int peer, uint16_t block, char *data, int size) /* * Receive a packet */ -jmp_buf timeoutbuf; +static jmp_buf timeoutbuf; static void timeout(int sig __unused) diff --git a/libexec/tftpd/tftp-utils.c b/libexec/tftpd/tftp-utils.c index 5613dd1a4925..c55f120a3a4d 100644 --- a/libexec/tftpd/tftp-utils.c +++ b/libexec/tftpd/tftp-utils.c @@ -121,7 +121,7 @@ get_field(int peer, char *buffer, ssize_t size) /* * Logging functions */ -int _tftp_logtostdout = 1; +static int _tftp_logtostdout = 1; void tftp_openlog(const char *ident, int logopt, int facility) diff --git a/libexec/tftpd/tftpd.c b/libexec/tftpd/tftpd.c index 16702b70cb1f..7363abf3c0e9 100644 --- a/libexec/tftpd/tftpd.c +++ b/libexec/tftpd/tftpd.c @@ -107,9 +107,9 @@ static void tftp_xmitfile(int peer, const char *mode); static int validate_access(int peer, char **, int); static char peername[NI_MAXHOST]; -FILE *file; +static FILE *file; -struct formats { +static struct formats { const char *f_mode; int f_convert; } formats[] = { |