mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-04 12:52:15 +00:00
Applied patch to make -Wall and -Dlint shut up.
Reviewed by: phk Submitted by: Josef Grosch <joeg@gagme.wwa.com>
This commit is contained in:
parent
1819efa6e7
commit
d4daf998ed
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=2923
@ -98,7 +98,7 @@ jcl(argv)
|
||||
|
||||
in.dbsz = out.dbsz = 512;
|
||||
|
||||
while (oper = *++argv) {
|
||||
while ((oper = *++argv)) {/* JEAG */
|
||||
if ((arg = strchr(oper, '=')) == NULL)
|
||||
errx(1, "unknown operand %s", oper);
|
||||
*arg++ = '\0';
|
||||
|
@ -59,7 +59,7 @@ def()
|
||||
int cnt;
|
||||
u_char *inp, *t;
|
||||
|
||||
if (t = ctab)
|
||||
if ((t = ctab))
|
||||
for (inp = in.dbp - (cnt = in.dbrcnt); cnt--; ++inp)
|
||||
*inp = t[*inp];
|
||||
|
||||
@ -103,6 +103,7 @@ block()
|
||||
int ch, cnt, maxlen;
|
||||
u_char *inp, *outp, *t;
|
||||
|
||||
ch = 0;
|
||||
/*
|
||||
* Record truncation can cross block boundaries. If currently in a
|
||||
* truncation state, keep tossing characters until reach a newline.
|
||||
@ -129,7 +130,7 @@ block()
|
||||
*/
|
||||
for (inp = in.dbp - in.dbcnt, outp = out.dbp; in.dbcnt;) {
|
||||
maxlen = MIN(cbsz, in.dbcnt);
|
||||
if (t = ctab)
|
||||
if ((t = ctab))
|
||||
for (cnt = 0;
|
||||
cnt < maxlen && (ch = *inp++) != '\n'; ++cnt)
|
||||
*outp++ = t[ch];
|
||||
@ -213,7 +214,7 @@ unblock()
|
||||
u_char *inp, *t;
|
||||
|
||||
/* Translation and case conversion. */
|
||||
if (t = ctab)
|
||||
if ((t = ctab))
|
||||
for (cnt = in.dbrcnt, inp = in.dbp; cnt--;)
|
||||
*--inp = t[*inp];
|
||||
/*
|
||||
|
@ -40,7 +40,7 @@ static char copyright[] =
|
||||
#ifndef lint
|
||||
/*static char sccsid[] = "From: @(#)hostname.c 8.1 (Berkeley) 5/31/93"; */
|
||||
static const char rcsid[] =
|
||||
"$Id$";
|
||||
"$Id: domainname.c,v 1.1 1994/09/18 21:23:37 wollman Exp $";
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -51,13 +51,15 @@ static const char rcsid[] =
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
|
||||
int getdomainname __P((char *, int));
|
||||
int setdomainname __P((const char *, int));
|
||||
|
||||
int
|
||||
main(argc,argv)
|
||||
int argc;
|
||||
char *argv[];
|
||||
{
|
||||
extern int optind;
|
||||
int ch, sflag;
|
||||
int sflag;
|
||||
char *p, domainname[MAXHOSTNAMELEN];
|
||||
|
||||
sflag = 0;
|
||||
|
@ -60,10 +60,10 @@ main(argc, argv)
|
||||
char *argv[];
|
||||
{
|
||||
int ch, exitval, oct, omode, pflag;
|
||||
mode_t *set;
|
||||
mode_t *set = (mode_t *)NULL;
|
||||
char *ep, *mode;
|
||||
|
||||
pflag = 0;
|
||||
omode = pflag = 0;
|
||||
mode = NULL;
|
||||
while ((ch = getopt(argc, argv, "m:p")) != EOF)
|
||||
switch(ch) {
|
||||
@ -123,10 +123,11 @@ build(path)
|
||||
char *p;
|
||||
|
||||
p = path;
|
||||
oumask = (mode_t)NULL;
|
||||
if (p[0] == '/') /* Skip leading '/'. */
|
||||
++p;
|
||||
for (first = 1;; ++p) {
|
||||
if (p[0] == '\0' || p[0] == '/' && p[1] == '\0')
|
||||
if (p[0] == '\0' || (p[0] == '/' && p[1] == '\0'))
|
||||
break;
|
||||
if (p[0] != '/')
|
||||
continue;
|
||||
|
@ -41,7 +41,9 @@ static char copyright[] =
|
||||
static char sccsid[] = "@(#)sync.c 8.1 (Berkeley) 5/31/93";
|
||||
#endif /* not lint */
|
||||
|
||||
main()
|
||||
void sync();
|
||||
|
||||
void main()
|
||||
{
|
||||
sync();
|
||||
exit(0);
|
||||
|
Loading…
Reference in New Issue
Block a user