Replace various spelling with FALLTHROUGH which is lint()able
This commit is contained in:
parent
c88222c6c0
commit
4966efff7b
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.apply.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
#include "def.edog.h"
|
||||
@ -37,7 +39,7 @@ doapply() {
|
||||
use_magic_whistle(obj);
|
||||
break;
|
||||
}
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case WHISTLE:
|
||||
use_whistle(obj);
|
||||
break;
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
#include <stdio.h>
|
||||
@ -496,7 +498,7 @@ struct monst *mtmp;
|
||||
case '+':
|
||||
if(x != u.ux && y != u.uy) break;
|
||||
if(flags.run != 1) goto stop;
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case CORR_SYM:
|
||||
corr:
|
||||
if(flags.run == 1 || flags.run == 3) {
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.do_name.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
#include <stdio.h>
|
||||
@ -209,7 +211,7 @@ extern char *shkname();
|
||||
(void) strcpy(buf, shkname(mtmp));
|
||||
break;
|
||||
}
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
(void) sprintf(buf, "the %s%s",
|
||||
mtmp->minvis ? "invisible " : "",
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.dog.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
#include "hack.mfndpos.h"
|
||||
@ -96,7 +98,7 @@ dogfood(obj) struct obj *obj; {
|
||||
);
|
||||
default:
|
||||
if(!obj->cursed) return(APPORT);
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case BALL_SYM:
|
||||
case CHAIN_SYM:
|
||||
case ROCK_SYM:
|
||||
@ -180,7 +182,7 @@ int info[9];
|
||||
|
||||
/* first we look for food */
|
||||
gtyp = UNDEF; /* no goal as yet */
|
||||
#ifdef LINT
|
||||
#ifdef lint
|
||||
gx = gy = 0; /* suppress 'used before set' message */
|
||||
#endif /* LINT */
|
||||
for(obj = fobj; obj; obj = obj->nobj) {
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.eat.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
char POISONOUS[] = "ADKSVabhks";
|
||||
@ -394,11 +396,11 @@ int tp = 0;
|
||||
case 'n':
|
||||
u.uhp = u.uhpmax;
|
||||
flags.botl = 1;
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case '@':
|
||||
pline("You cannibal! You will be sorry for this!");
|
||||
/* not tp++; */
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case 'd':
|
||||
Aggravate_monster |= INTRINSIC;
|
||||
break;
|
||||
@ -411,12 +413,12 @@ int tp = 0;
|
||||
Invis |= INTRINSIC;
|
||||
See_invisible |= INTRINSIC;
|
||||
}
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case 'y':
|
||||
#ifdef QUEST
|
||||
u.uhorizon++;
|
||||
#endif /* QUEST */
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case 'B':
|
||||
Confusion = 50;
|
||||
break;
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.mkobj.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
|
||||
@ -76,7 +78,7 @@ int otyp;
|
||||
if(otmp->otyp == TIN)
|
||||
otmp->spe = rnd(...);
|
||||
#endif /* NOT_YET_IMPLEMENTED */
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case GEM_SYM:
|
||||
otmp->quan = rn2(6) ? 1 : 2;
|
||||
case TOOL_SYM:
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.objnam.c - version 1.0.2 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
#define Sprintf (void) sprintf
|
||||
@ -112,7 +114,7 @@ int pl = (obj->quan != 1);
|
||||
break;
|
||||
}
|
||||
/* fungis ? */
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case WEAPON_SYM:
|
||||
if(obj->otyp == WORM_TOOTH && pl) {
|
||||
pl = 0;
|
||||
@ -124,7 +126,7 @@ int pl = (obj->quan != 1);
|
||||
Strcpy(buf, "crysknives");
|
||||
break;
|
||||
}
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case ARMOR_SYM:
|
||||
case CHAIN_SYM:
|
||||
case ROCK_SYM:
|
||||
@ -258,7 +260,7 @@ char *bp = xname(obj);
|
||||
case ARMOR_SYM:
|
||||
if(obj->owornmask & W_ARMOR)
|
||||
Strcat(bp, " (being worn)");
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case WEAPON_SYM:
|
||||
if(obj->known) {
|
||||
Strcat(prefix, sitoa(obj->spe));
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.trap.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
|
||||
@ -256,7 +258,7 @@ float_down(){
|
||||
break;
|
||||
case TRAPDOOR:
|
||||
if(!xdnstair || u.ustuck) break;
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
dotrap(trap);
|
||||
}
|
||||
|
@ -1,9 +1,11 @@
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/* hack.wizard.c - version 1.0.3 */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
/* wizard code - inspired by rogue code from Merlyn Leroy (digi-g!brian) */
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include "hack.h"
|
||||
extern struct permonst pm_wizard;
|
||||
extern struct monst *makemon();
|
||||
@ -137,7 +139,7 @@ struct monst *mtmp;
|
||||
case 1:
|
||||
pline("\"Destroy the thief, my pets!\"");
|
||||
aggravate(); /* aggravate all the monsters */
|
||||
/* fall into next case */
|
||||
/* FALLTHROUGH */
|
||||
case 2:
|
||||
if (flags.no_of_wizards == 1 && rnd(5) == 0)
|
||||
/* if only 1 wizard, clone himself */
|
||||
|
@ -1549,7 +1549,7 @@ double dtemp; /* for temporary calculations */
|
||||
}
|
||||
}
|
||||
/* end treasure types 10 - 13 */
|
||||
/* fall through to treasure type 9 if no treasure from above */
|
||||
/* FALLTHROUGH to treasure type 9 if no treasure from above */
|
||||
|
||||
case 9: /* treasure type 9 */
|
||||
switch (whichtreasure)
|
||||
@ -1563,7 +1563,7 @@ double dtemp; /* for temporary calculations */
|
||||
++Player.p_crowns;
|
||||
break;
|
||||
}
|
||||
/* fall through otherwise */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case 2:
|
||||
addstr("You've been blessed!\n");
|
||||
|
@ -1114,7 +1114,7 @@ int operation;
|
||||
case A_NEAR: /* pick random coordinates near */
|
||||
xnew = Player.p_x + ROLL(1.0, 5.0);
|
||||
ynew = Player.p_y - ROLL(1.0, 5.0);
|
||||
/* fall through for check */
|
||||
/* FALLTHROUGH for check */
|
||||
|
||||
case A_SPECIFIC: /* just move player */
|
||||
if (Beyond && fabs(xnew) < D_BEYOND && fabs(ynew) < D_BEYOND)
|
||||
|
@ -167,7 +167,7 @@ Field(buf, out, len)
|
||||
|
||||
case 'h': case 'H':
|
||||
base16 = 1;
|
||||
/* fall into */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
default:
|
||||
*--bp = 0; /* Ends Loop */
|
||||
|
@ -91,7 +91,7 @@ spectHex(p0)
|
||||
|
||||
case 'a': case 'b': case 'c': case 'd': case 'e': case 'f':
|
||||
*p += ('A' - 'a');
|
||||
/* fall into . . . */
|
||||
/* FALLTHROUGH */
|
||||
case 'A': case 'B': case 'C': case 'D': case 'E': case 'F':
|
||||
ok = 1;
|
||||
case '1': case '2': case '3': case '4': case '5':
|
||||
|
@ -1741,7 +1741,7 @@ struct re_guts *g;
|
||||
return;
|
||||
}
|
||||
} while (OP(s) != O_QUEST && OP(s) != O_CH);
|
||||
/* fallthrough */
|
||||
/* FALLTHROUGH */
|
||||
case OBOW: /* things that break a sequence */
|
||||
case OEOW:
|
||||
case OBOL:
|
||||
|
@ -394,7 +394,7 @@ _thread_kern_scheduler(void)
|
||||
case PS_SELECT_WAIT:
|
||||
/* Return zero file descriptors ready: */
|
||||
pthread->data.poll_data->nfds = 0;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
/*
|
||||
* Remove this thread from the waiting queue
|
||||
|
@ -169,7 +169,7 @@ Field(buf, out, len)
|
||||
|
||||
case 'h': case 'H':
|
||||
base16 = 1;
|
||||
/* fall into */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
default:
|
||||
*--bp = 0; /* Ends Loop */
|
||||
|
@ -394,7 +394,7 @@ _thread_kern_scheduler(void)
|
||||
case PS_SELECT_WAIT:
|
||||
/* Return zero file descriptors ready: */
|
||||
pthread->data.poll_data->nfds = 0;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
/*
|
||||
* Remove this thread from the waiting queue
|
||||
|
@ -394,7 +394,7 @@ _thread_kern_scheduler(void)
|
||||
case PS_SELECT_WAIT:
|
||||
/* Return zero file descriptors ready: */
|
||||
pthread->data.poll_data->nfds = 0;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
/*
|
||||
* Remove this thread from the waiting queue
|
||||
|
@ -245,7 +245,7 @@ login_getclassbyname(char const *name, const struct passwd *pwd)
|
||||
msg = "%s: no default/fallback class '%s'";
|
||||
if (cgetent(&lc->lc_cap, login_dbarray, (char*)name) != 0 && r >= 0)
|
||||
break;
|
||||
/* Fallthru - just return system defaults */
|
||||
/* FALLTHROUGH - just return system defaults */
|
||||
case 0: /* success! */
|
||||
if ((lc->lc_class = strdup(name)) != NULL) {
|
||||
if (dir) {
|
||||
|
@ -85,7 +85,7 @@ properties_read(int fd)
|
||||
ch = buf[0];
|
||||
bp = 1;
|
||||
}
|
||||
/* Fall through deliberately since we already have a character and state == LOOK */
|
||||
/* FALLTHROUGH deliberately since we already have a character and state == LOOK */
|
||||
|
||||
case LOOK:
|
||||
if (isspace(ch))
|
||||
|
@ -577,7 +577,8 @@ read_entry(fp, buffer, bufsiz)
|
||||
case '\\':
|
||||
if ((c = fgetc(fp)) < 0) { /* Backslash */
|
||||
goto done; /* EOF. . . .*/
|
||||
} /* else fall through */
|
||||
}
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
*buffer++ = c; /* Other character, store it */
|
||||
length++;
|
||||
@ -608,7 +609,7 @@ read_entry(fp, buffer, bufsiz)
|
||||
goto top; /* Backslash-newline continuation */
|
||||
}
|
||||
}
|
||||
/* fall through if "other" character */
|
||||
/* FALLTHROUGH if "other" character */
|
||||
default:
|
||||
*buffer++ = c; /* Store other characters */
|
||||
length++;
|
||||
|
@ -103,7 +103,7 @@ telrcv(void)
|
||||
if ((c == 0) || (c == '\n')) {
|
||||
break;
|
||||
}
|
||||
/* FALL THROUGH */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case TS_DATA:
|
||||
if (c == IAC) {
|
||||
@ -1256,7 +1256,7 @@ suboption(void)
|
||||
case ENV_ESC:
|
||||
if (!SB_EOF())
|
||||
c = SB_GET();
|
||||
/* FALL THROUGH */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
empty = 0;
|
||||
continue;
|
||||
@ -1343,7 +1343,7 @@ suboption(void)
|
||||
if (SB_EOF())
|
||||
break;
|
||||
c = SB_GET();
|
||||
/* FALL THROUGH */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
*cp++ = c;
|
||||
break;
|
||||
|
@ -458,13 +458,13 @@ dumpino(union dinode *dp, ino_t ino)
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case S_IFDIR:
|
||||
case S_IFREG:
|
||||
if (DIP(dp, di_size) > 0)
|
||||
break;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case S_IFIFO:
|
||||
case S_IFSOCK:
|
||||
|
@ -31,13 +31,14 @@
|
||||
* SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef lint
|
||||
#if 0
|
||||
#ifndef lint
|
||||
static const char sccsid[] = "@(#)pass2.c 8.9 (Berkeley) 4/28/95";
|
||||
#endif
|
||||
static const char rcsid[] =
|
||||
"$FreeBSD$";
|
||||
#endif /* not lint */
|
||||
#endif
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include <sys/param.h>
|
||||
|
||||
@ -406,7 +407,7 @@ pass2check(struct inodesc *idesc)
|
||||
case DSTATE:
|
||||
if (inoinfo(idesc->id_number)->ino_state == DFOUND)
|
||||
inoinfo(dirp->d_ino)->ino_state = DFOUND;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case DFOUND:
|
||||
inp = getinoinfo(dirp->d_ino);
|
||||
@ -431,7 +432,7 @@ pass2check(struct inodesc *idesc)
|
||||
}
|
||||
if (idesc->id_entryno > 2)
|
||||
inp->i_parent = idesc->id_number;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case FSTATE:
|
||||
if (dirp->d_type != inoinfo(dirp->d_ino)->ino_type) {
|
||||
|
@ -31,13 +31,14 @@
|
||||
* SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef lint
|
||||
#if 0
|
||||
#ifndef lint
|
||||
static const char sccsid[] = "@(#)pass5.c 8.9 (Berkeley) 4/28/95";
|
||||
#endif
|
||||
static const char rcsid[] =
|
||||
"$FreeBSD$";
|
||||
#endif /* not lint */
|
||||
#endif
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__FBSDID("$FreeBSD$");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/sysctl.h>
|
||||
@ -215,7 +216,7 @@ pass5(void)
|
||||
case DCLEAR:
|
||||
case DFOUND:
|
||||
newcg->cg_cs.cs_ndir++;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
case FSTATE:
|
||||
case FCLEAR:
|
||||
|
@ -594,7 +594,7 @@ mkentry(char *name, struct direct *dp, struct afile *fp)
|
||||
default:
|
||||
fprintf(stderr, "Warning: undefined file type %d\n",
|
||||
dp->d_type);
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
case DT_REG:
|
||||
fp->postfix = ' ';
|
||||
break;
|
||||
|
@ -321,7 +321,7 @@ nodeupdates(char *name, ino_t ino, int type)
|
||||
} else {
|
||||
mktempname(np);
|
||||
}
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
|
||||
/*
|
||||
* A previously non-existent file.
|
||||
@ -352,7 +352,7 @@ nodeupdates(char *name, ino_t ino, int type)
|
||||
case ONTAPE|INOFND:
|
||||
if (type == LEAF && (ip->e_flags & KEEP) == 0)
|
||||
ip->e_flags |= EXTRACT;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
case INOFND:
|
||||
if ((ip->e_flags & KEEP) == 0) {
|
||||
renameit(myname(ip), name);
|
||||
|
@ -727,7 +727,7 @@ supply(struct sockaddr_in *dst,
|
||||
|
||||
case OUT_QUERY:
|
||||
ws.state |= WS_ST_QUERY;
|
||||
/* fall through */
|
||||
/* FALLTHROUGH */
|
||||
case OUT_BROADCAST:
|
||||
case OUT_UNICAST:
|
||||
v2buf.type = (vers == RIPv2) ? type : NO_OUT_RIPV2;
|
||||
|
@ -596,7 +596,7 @@ show_var(int *oid, int nlen)
|
||||
printf("%s%s", name, sep);
|
||||
return ((*func)(len, p));
|
||||
}
|
||||
/* FALL THROUGH */
|
||||
/* FALLTHROUGH */
|
||||
default:
|
||||
if (!oflag && !xflag)
|
||||
return (1);
|
||||
|
Loading…
Reference in New Issue
Block a user