summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/mountd/mountd.c2
-rw-r--r--usr.sbin/pstat/pstat.c2
-rw-r--r--usr.sbin/pw/cpdir.c5
-rw-r--r--usr.sbin/quot/quot.c4
4 files changed, 2 insertions, 11 deletions
diff --git a/usr.sbin/mountd/mountd.c b/usr.sbin/mountd/mountd.c
index 8b03e13..54dfd69 100644
--- a/usr.sbin/mountd/mountd.c
+++ b/usr.sbin/mountd/mountd.c
@@ -568,7 +568,6 @@ mntsrv(rqstp, transp)
struct fhreturn fhr;
struct stat stb;
struct statfs fsb;
- struct addrinfo *ai;
char host[NI_MAXHOST], numerichost[NI_MAXHOST];
int lookup_failed = 1;
struct sockaddr *saddr;
@@ -595,7 +594,6 @@ mntsrv(rqstp, transp)
NULL, 0, 0);
getnameinfo(saddr, saddr->sa_len, numerichost,
sizeof numerichost, NULL, 0, NI_NUMERICHOST);
- ai = NULL;
switch (rqstp->rq_proc) {
case NULLPROC:
if (!svc_sendreply(transp, (xdrproc_t)xdr_void, NULL))
diff --git a/usr.sbin/pstat/pstat.c b/usr.sbin/pstat/pstat.c
index ca78637..519f4d8 100644
--- a/usr.sbin/pstat/pstat.c
+++ b/usr.sbin/pstat/pstat.c
@@ -336,7 +336,6 @@ static void
ttyprt(struct xtty *xt)
{
int i, j;
- pid_t pgid;
char *name, state[20];
if (xt->xt_size != sizeof *xt)
@@ -357,7 +356,6 @@ ttyprt(struct xtty *xt)
state[j++] = '-';
state[j] = '\0';
(void)printf("%-6s %8d", state, xt->xt_sid);
- pgid = 0;
(void)printf("%6d ", xt->xt_pgid);
switch (xt->xt_line) {
case TTYDISC:
diff --git a/usr.sbin/pw/cpdir.c b/usr.sbin/pw/cpdir.c
index d8fa42b..1eba348 100644
--- a/usr.sbin/pw/cpdir.c
+++ b/usr.sbin/pw/cpdir.c
@@ -46,7 +46,6 @@ static const char rcsid[] =
void
copymkdir(char const * dir, char const * skel, mode_t mode, uid_t uid, gid_t gid)
{
- int rc = 0;
char src[MAXPATHLEN];
char dst[MAXPATHLEN];
@@ -61,9 +60,7 @@ copymkdir(char const * dir, char const * skel, mode_t mode, uid_t uid, gid_t gid
++counter;
chown(dir, uid, gid);
- if (skel == NULL || *skel == '\0')
- rc = 1;
- else {
+ if (skel != NULL && *skel != '\0') {
DIR *d = opendir(skel);
if (d != NULL) {
diff --git a/usr.sbin/quot/quot.c b/usr.sbin/quot/quot.c
index 75e758b..42e8f48 100644
--- a/usr.sbin/quot/quot.c
+++ b/usr.sbin/quot/quot.c
@@ -477,7 +477,7 @@ donames(fd, super, name)
char *name;
{
int c;
- ino_t inode, inode1;
+ ino_t inode;
ino_t maxino;
union dinode *dp;
@@ -486,7 +486,6 @@ donames(fd, super, name)
while ((c = getchar()) != EOF && (c < '0' || c > '9'))
while ((c = getchar()) != EOF && c != '\n');
ungetc(c,stdin);
- inode1 = -1;
while (scanf("%u",&inode) == 1) {
if (inode > maxino) {
warnx("illegal inode %d",inode);
@@ -504,7 +503,6 @@ donames(fd, super, name)
c = getchar();
}
putchar('\n');
- inode1 = inode;
} else {
if (errno) {
err(1, "%s", name);
OpenPOWER on IntegriCloud