Remove unused variables and assignments.
This commit is contained in:
parent
087a85c41b
commit
4bb1e32851
@ -254,7 +254,6 @@ rangematch(pattern, test, flags, newp, patmbs)
|
|||||||
} else if (*pattern == '\0') {
|
} else if (*pattern == '\0') {
|
||||||
return (RANGE_ERROR);
|
return (RANGE_ERROR);
|
||||||
} else if (*pattern == '/' && (flags & FNM_PATHNAME)) {
|
} else if (*pattern == '/' && (flags & FNM_PATHNAME)) {
|
||||||
pattern++;
|
|
||||||
return (RANGE_NOMATCH);
|
return (RANGE_NOMATCH);
|
||||||
} else if (*pattern == '\\' && !(flags & FNM_NOESCAPE))
|
} else if (*pattern == '\\' && !(flags & FNM_NOESCAPE))
|
||||||
pattern++;
|
pattern++;
|
||||||
|
@ -60,14 +60,12 @@ getifmaddrs(struct ifmaddrs **pif)
|
|||||||
int icnt = 1;
|
int icnt = 1;
|
||||||
int dcnt = 0;
|
int dcnt = 0;
|
||||||
int ntry = 0;
|
int ntry = 0;
|
||||||
u_short idx = 0;
|
|
||||||
size_t len;
|
size_t len;
|
||||||
size_t needed;
|
size_t needed;
|
||||||
int mib[6];
|
int mib[6];
|
||||||
int i;
|
int i;
|
||||||
char *buf;
|
char *buf;
|
||||||
char *data;
|
char *data;
|
||||||
char *names;
|
|
||||||
char *next;
|
char *next;
|
||||||
char *p;
|
char *p;
|
||||||
struct ifma_msghdr *ifmam;
|
struct ifma_msghdr *ifmam;
|
||||||
@ -128,12 +126,10 @@ getifmaddrs(struct ifmaddrs **pif)
|
|||||||
|
|
||||||
ifa = (struct ifmaddrs *)(void *)data;
|
ifa = (struct ifmaddrs *)(void *)data;
|
||||||
data += sizeof(struct ifmaddrs) * icnt;
|
data += sizeof(struct ifmaddrs) * icnt;
|
||||||
names = data + dcnt;
|
|
||||||
|
|
||||||
memset(ifa, 0, sizeof(struct ifmaddrs) * icnt);
|
memset(ifa, 0, sizeof(struct ifmaddrs) * icnt);
|
||||||
ift = ifa;
|
ift = ifa;
|
||||||
|
|
||||||
idx = 0;
|
|
||||||
for (next = buf; next < buf + needed; next += rtm->rtm_msglen) {
|
for (next = buf; next < buf + needed; next += rtm->rtm_msglen) {
|
||||||
rtm = (struct rt_msghdr *)(void *)next;
|
rtm = (struct rt_msghdr *)(void *)next;
|
||||||
if (rtm->rtm_version != RTM_VERSION)
|
if (rtm->rtm_version != RTM_VERSION)
|
||||||
|
@ -158,7 +158,7 @@ int
|
|||||||
res_hnok(dn)
|
res_hnok(dn)
|
||||||
const char *dn;
|
const char *dn;
|
||||||
{
|
{
|
||||||
int ppch = '\0', pch = PERIOD, ch = *dn++;
|
int pch = PERIOD, ch = *dn++;
|
||||||
|
|
||||||
while (ch != '\0') {
|
while (ch != '\0') {
|
||||||
int nch = *dn++;
|
int nch = *dn++;
|
||||||
@ -175,7 +175,7 @@ res_hnok(dn)
|
|||||||
if (!middlechar(ch))
|
if (!middlechar(ch))
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
ppch = pch, pch = ch, ch = nch;
|
pch = ch, ch = nch;
|
||||||
}
|
}
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
|
@ -62,7 +62,7 @@ int
|
|||||||
res_mkupdate(ns_updrec *rrecp_in, u_char *buf, int buflen) {
|
res_mkupdate(ns_updrec *rrecp_in, u_char *buf, int buflen) {
|
||||||
ns_updrec *rrecp_start = rrecp_in;
|
ns_updrec *rrecp_start = rrecp_in;
|
||||||
HEADER *hp;
|
HEADER *hp;
|
||||||
u_char *cp, *sp1, *sp2, *startp, *endp;
|
u_char *cp, *sp2, *startp, *endp;
|
||||||
int n, i, soanum, multiline;
|
int n, i, soanum, multiline;
|
||||||
ns_updrec *rrecp;
|
ns_updrec *rrecp;
|
||||||
struct in_addr ina;
|
struct in_addr ina;
|
||||||
@ -87,7 +87,6 @@ res_mkupdate(ns_updrec *rrecp_in, u_char *buf, int buflen) {
|
|||||||
hp->id = htons(++_res.id);
|
hp->id = htons(++_res.id);
|
||||||
hp->opcode = ns_o_update;
|
hp->opcode = ns_o_update;
|
||||||
hp->rcode = NOERROR;
|
hp->rcode = NOERROR;
|
||||||
sp1 = buf + 2*INT16SZ; /* save pointer to zocount */
|
|
||||||
cp = buf + HFIXEDSZ;
|
cp = buf + HFIXEDSZ;
|
||||||
buflen -= HFIXEDSZ;
|
buflen -= HFIXEDSZ;
|
||||||
dpp = dnptrs;
|
dpp = dnptrs;
|
||||||
|
Loading…
Reference in New Issue
Block a user