fix unused variable warnings
This commit is contained in:
parent
0a77b69ab6
commit
193b880fad
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: ttext2.c,v 1.9 2010/03/22 05:10:19 mrg Exp $ */
|
||||
/* $NetBSD: ttext2.c,v 1.10 2013/10/19 17:23:08 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1980, 1993
|
||||
@ -34,7 +34,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)ttext2.c 8.1 (Berkeley) 5/31/93";
|
||||
#else
|
||||
__RCSID("$NetBSD: ttext2.c,v 1.9 2010/03/22 05:10:19 mrg Exp $");
|
||||
__RCSID("$NetBSD: ttext2.c,v 1.10 2013/10/19 17:23:08 christos Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
@ -129,14 +129,12 @@ const char *const lastch[] = {
|
||||
int
|
||||
wrtext(const char *const *txt)
|
||||
{
|
||||
const char *const *begin;
|
||||
const char *a;
|
||||
char b;
|
||||
const char *c;
|
||||
int i;
|
||||
|
||||
fixtty(&noech);
|
||||
begin = txt;
|
||||
while (*txt) {
|
||||
a = *(txt++);
|
||||
if (*a != '\0') {
|
||||
@ -187,7 +185,6 @@ wrtext(const char *const *txt)
|
||||
fixtty(&noech);
|
||||
if (tflag)
|
||||
curmove(curr, 0);
|
||||
begin = txt;
|
||||
}
|
||||
}
|
||||
fixtty(&raw);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: prtable.c,v 1.9 2005/07/01 16:38:24 jmc Exp $ */
|
||||
/* $NetBSD: prtable.c,v 1.10 2013/10/19 17:23:08 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1993
|
||||
@ -36,7 +36,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: prtable.c,v 1.9 2005/07/01 16:38:24 jmc Exp $");
|
||||
__RCSID("$NetBSD: prtable.c,v 1.10 2013/10/19 17:23:08 christos Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include <curses.h>
|
||||
@ -106,6 +106,7 @@ prtable(const char *const base[], int num, int d_cols, int width,
|
||||
}
|
||||
}
|
||||
getyx(stdscr, row, col);
|
||||
__USE(col);
|
||||
move(row + 1, 0);
|
||||
}
|
||||
refresh();
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pickmove.c,v 1.21 2012/10/13 20:57:35 dholland Exp $ */
|
||||
/* $NetBSD: pickmove.c,v 1.22 2013/10/19 17:23:08 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994
|
||||
@ -37,7 +37,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)pickmove.c 8.2 (Berkeley) 5/3/95";
|
||||
#else
|
||||
__RCSID("$NetBSD: pickmove.c,v 1.21 2012/10/13 20:57:35 dholland Exp $");
|
||||
__RCSID("$NetBSD: pickmove.c,v 1.22 2013/10/19 17:23:08 christos Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
@ -1083,7 +1083,7 @@ checkframes(struct combostr *cbp, struct combostr *fcbp, struct spotstr *osp,
|
||||
int s, struct overlap_info *vertices)
|
||||
{
|
||||
struct combostr *tcbp, *lcbp;
|
||||
int i, n, mask, flags, verts, loop, myindex, fcnt;
|
||||
int i, n, mask, flags, verts, myindex, fcnt;
|
||||
union comboval cb;
|
||||
u_char *str;
|
||||
short *ip;
|
||||
@ -1094,7 +1094,6 @@ checkframes(struct combostr *cbp, struct combostr *fcbp, struct spotstr *osp,
|
||||
cb.s = s;
|
||||
fcnt = cb.c.a - 2;
|
||||
verts = 0;
|
||||
loop = 0;
|
||||
myindex = cbp->c_nframes;
|
||||
n = (fcbp - frames) * FAREA;
|
||||
str = &overlap[n];
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: driver.c,v 1.21 2011/08/31 16:24:56 plunky Exp $ */
|
||||
/* $NetBSD: driver.c,v 1.22 2013/10/19 17:23:08 christos Exp $ */
|
||||
/*
|
||||
* Copyright (c) 1983-2003, Regents of the University of California.
|
||||
* All rights reserved.
|
||||
@ -32,7 +32,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: driver.c,v 1.21 2011/08/31 16:24:56 plunky Exp $");
|
||||
__RCSID("$NetBSD: driver.c,v 1.22 2013/10/19 17:23:08 christos Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/ioctl.h>
|
||||
@ -88,7 +88,7 @@ main(int ac, char **av, char **ep)
|
||||
PLAYER *pp;
|
||||
#ifdef INTERNET
|
||||
u_short msg;
|
||||
short port_num, reply;
|
||||
short reply;
|
||||
socklen_t namelen;
|
||||
SOCKET test;
|
||||
#endif
|
||||
@ -143,7 +143,6 @@ again:
|
||||
#ifdef INTERNET
|
||||
if (fdset[2].revents & POLLIN) {
|
||||
namelen = DAEMON_SIZE;
|
||||
port_num = htons(sock_port);
|
||||
(void) recvfrom(Test_socket, &msg, sizeof msg,
|
||||
0, (struct sockaddr *) &test, &namelen);
|
||||
switch (ntohs(msg)) {
|
||||
@ -599,7 +598,6 @@ zap(PLAYER *pp, FLAG was_player, int i)
|
||||
BULLET *bp;
|
||||
PLAYER *np;
|
||||
int x, y;
|
||||
int savefd;
|
||||
|
||||
if (was_player) {
|
||||
if (pp->p_undershot)
|
||||
@ -622,8 +620,6 @@ zap(PLAYER *pp, FLAG was_player, int i)
|
||||
outstr(pp, pp->p_death, len);
|
||||
cgoto(pp, HEIGHT, 0);
|
||||
|
||||
savefd = pp->p_fd;
|
||||
|
||||
#ifdef MONITOR
|
||||
if (was_player) {
|
||||
#endif
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: sync.c,v 1.33 2009/03/14 23:47:18 dholland Exp $ */
|
||||
/* $NetBSD: sync.c,v 1.34 2013/10/19 17:23:08 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1993
|
||||
@ -34,7 +34,7 @@
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)sync.c 8.2 (Berkeley) 4/28/95";
|
||||
#else
|
||||
__RCSID("$NetBSD: sync.c,v 1.33 2009/03/14 23:47:18 dholland Exp $");
|
||||
__RCSID("$NetBSD: sync.c,v 1.34 2013/10/19 17:23:08 christos Exp $");
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
@ -247,13 +247,12 @@ int
|
||||
sync_open(void)
|
||||
{
|
||||
const char *sync_file;
|
||||
const char *sync_lock;
|
||||
struct stat tmp;
|
||||
|
||||
if (sync_fp != NULL)
|
||||
fclose(sync_fp);
|
||||
sync_file = get_sync_file(game);
|
||||
sync_lock = get_lock_file(game);
|
||||
(void)get_lock_file(game);
|
||||
setegid(egid);
|
||||
if (stat(sync_file, &tmp) < 0) {
|
||||
mode_t omask = umask(002);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: scores.c,v 1.20 2011/01/05 15:48:00 wiz Exp $ */
|
||||
/* $NetBSD: scores.c,v 1.21 2013/10/19 17:23:08 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1992, 1993
|
||||
@ -381,9 +381,8 @@ getscores(int *fdp)
|
||||
struct highscore_header header;
|
||||
int sd, mint, lck;
|
||||
mode_t mask;
|
||||
const char *mstr, *human;
|
||||
const char *human;
|
||||
int doflip;
|
||||
int serrno;
|
||||
ssize_t result;
|
||||
|
||||
#ifdef ALLOW_SCORE_UPDATES
|
||||
@ -395,14 +394,12 @@ getscores(int *fdp)
|
||||
#endif
|
||||
{
|
||||
mint = O_RDONLY;
|
||||
mstr = "r";
|
||||
human = "reading";
|
||||
lck = LOCK_SH;
|
||||
}
|
||||
setegid(egid);
|
||||
mask = umask(S_IWOTH);
|
||||
sd = open(_PATH_SCOREFILE, mint, 0666);
|
||||
serrno = errno;
|
||||
(void)umask(mask);
|
||||
setegid(gid);
|
||||
if (sd < 0) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: rtld.c,v 1.169 2013/05/09 15:47:34 skrll Exp $ */
|
||||
/* $NetBSD: rtld.c,v 1.170 2013/10/19 17:19:30 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1996 John D. Polstra.
|
||||
@ -40,7 +40,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: rtld.c,v 1.169 2013/05/09 15:47:34 skrll Exp $");
|
||||
__RCSID("$NetBSD: rtld.c,v 1.170 2013/10/19 17:19:30 christos Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -1290,6 +1290,7 @@ dladdr(const void *addr, Dl_info *info)
|
||||
info->dli_saddr = symbol_addr;
|
||||
best_def = def;
|
||||
|
||||
|
||||
/* Exact match? */
|
||||
if (info->dli_saddr == addr)
|
||||
break;
|
||||
@ -1299,6 +1300,8 @@ dladdr(const void *addr, Dl_info *info)
|
||||
if (best_def != NULL && ELF_ST_TYPE(best_def->st_info) == STT_FUNC)
|
||||
info->dli_saddr = (void *)_rtld_function_descriptor_alloc(obj,
|
||||
best_def, 0);
|
||||
#else
|
||||
__USE(best_def);
|
||||
#endif /* __HAVE_FUNCTION_DESCRIPTORS */
|
||||
|
||||
lookup_mutex_exit();
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: lfs_cleanerd.c,v 1.36 2013/06/18 18:18:57 christos Exp $ */
|
||||
/* $NetBSD: lfs_cleanerd.c,v 1.37 2013/10/19 17:19:30 christos Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2005 The NetBSD Foundation, Inc.
|
||||
@ -1353,7 +1353,9 @@ lfs_cleaner_main(int argc, char **argv)
|
||||
{
|
||||
int i, opt, error, r, loopcount, nodetach;
|
||||
struct timeval tv;
|
||||
#ifdef LFS_CLEANER_AS_LIB
|
||||
sem_t *semaddr = NULL;
|
||||
#endif
|
||||
CLEANERINFO ci;
|
||||
#ifndef USE_CLIENT_SERVER
|
||||
char *cp, *pidname;
|
||||
@ -1414,13 +1416,11 @@ lfs_cleaner_main(int argc, char **argv)
|
||||
case 's': /* Small writes */
|
||||
do_small = 1;
|
||||
break;
|
||||
#ifdef LFS_CLEANER_AS_LIB
|
||||
case 'S': /* semaphore */
|
||||
#ifndef LFS_CLEANER_AS_LIB
|
||||
usage();
|
||||
/*NOTREACHED*/
|
||||
#endif
|
||||
semaddr = (void*)(uintptr_t)strtoull(optarg,NULL,0);
|
||||
break;
|
||||
#endif
|
||||
case 't': /* timeout */
|
||||
segwait_timeout = atoi(optarg);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user