Fix some warnings.

The last one left seems like a genuine one and I'm not sure about the
correct fix. I think that I'm going to remove that block of code
after refactoring tho, so I'm leaving it there for now.
This commit is contained in:
King_DuckZ 2020-03-03 14:02:53 +01:00
parent 289444bb63
commit 9525cc69bd

View file

@ -476,11 +476,9 @@ parse_rr(pnt, len, cont_flag)
int cont_flag;
{
int slen;
int xlen;
int ncount;
int pl_extent;
int cont_extent, cont_offset, cont_size;
int flag1, flag2;
int flag2;
unsigned char *pnts;
char symlinkname[1024];
int goof = 0;
@ -490,7 +488,6 @@ parse_rr(pnt, len, cont_flag)
cl_extent = cont_extent = cont_offset = cont_size = 0;
ncount = 0;
flag1 = -1;
flag2 = 0;
while (len >= 4) {
if (pnt[3] != 1 && pnt[3] != 2) {
@ -503,7 +500,6 @@ parse_rr(pnt, len, cont_flag)
}
ncount++;
if (pnt[0] == 'R' && pnt[1] == 'R') flag1 = pnt[4] & 0xff;
if (strncmp((char *)pnt, "PX", 2) == 0) flag2 |= RR_FLAG_PX; /* POSIX attributes */
if (strncmp((char *)pnt, "PN", 2) == 0) flag2 |= RR_FLAG_PN; /* POSIX device number */
if (strncmp((char *)pnt, "SL", 2) == 0) flag2 |= RR_FLAG_SL; /* Symlink */
@ -601,14 +597,8 @@ parse_rr(pnt, len, cont_flag)
if (strncmp((char *)pnt, "CL", 2) == 0) {
cl_extent = isonum_733(pnt+4); /* Child link location */
}
if (strncmp((char *)pnt, "PL", 2) == 0) {
pl_extent = isonum_733(pnt+4); /* Parent link location */
}
if (strncmp((char *)pnt, "SL", 2) == 0) { /* Symlink */
int cflag;
cflag = pnt[4];
pnts = pnt+5;
slen = pnt[2] - 5;
while (slen >= 1) {
@ -648,7 +638,6 @@ parse_rr(pnt, len, cont_flag)
strcpy(xname, "-> ");
strcat(xname, symlinkname);
symlinkname[0] = 0;
xlen = strlen(xname);
if ((pnts[0] & 1) == 0)
strcat(xname, "/");