=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/make/suff.c,v retrieving revision 1.24 retrieving revision 1.25 diff -c -r1.24 -r1.25 *** src/usr.bin/make/suff.c 2000/03/26 15:51:31 1.24 --- src/usr.bin/make/suff.c 2000/03/26 16:21:33 1.25 *************** *** 1,4 **** ! /* $OpenBSD: suff.c,v 1.24 2000/03/26 15:51:31 espie Exp $ */ /* $NetBSD: suff.c,v 1.13 1996/11/06 17:59:25 christos Exp $ */ /* --- 1,4 ---- ! /* $OpenBSD: suff.c,v 1.25 2000/03/26 16:21:33 espie Exp $ */ /* $NetBSD: suff.c,v 1.13 1996/11/06 17:59:25 christos Exp $ */ /* *************** *** 43,49 **** #if 0 static char sccsid[] = "@(#)suff.c 8.4 (Berkeley) 3/21/94"; #else ! static char rcsid[] = "$OpenBSD: suff.c,v 1.24 2000/03/26 15:51:31 espie Exp $"; #endif #endif /* not lint */ --- 43,49 ---- #if 0 static char sccsid[] = "@(#)suff.c 8.4 (Berkeley) 3/21/94"; #else ! static char rcsid[] = "$OpenBSD: suff.c,v 1.25 2000/03/26 16:21:33 espie Exp $"; #endif #endif /* not lint */ *************** *** 389,395 **** Lst l; Suff *s; { ! SuffUnRef((ClientData) l, (ClientData) s); } /*- --- 389,395 ---- Lst l; Suff *s; { ! SuffUnRef(l, s); } /*- *************** *** 431,444 **** if (DEBUG(SUFF)) { printf("at end of list\n"); } ! Lst_AtEnd (l, (ClientData)s); ! Lst_AtEnd(s->ref, (ClientData) l); } else if (s2->sNum != s->sNum) { if (DEBUG(SUFF)) { printf("before %s(%d)\n", s2->name, s2->sNum); } ! Lst_Insert(l, ln, (ClientData)s); ! Lst_AtEnd(s->ref, (ClientData) l); } else if (DEBUG(SUFF)) { printf("already there\n"); } --- 431,444 ---- if (DEBUG(SUFF)) { printf("at end of list\n"); } ! Lst_AtEnd(l, s); ! Lst_AtEnd(s->ref, l); } else if (s2->sNum != s->sNum) { if (DEBUG(SUFF)) { printf("before %s(%d)\n", s2->name, s2->sNum); } ! Lst_Insert(l, ln, s); ! Lst_AtEnd(s->ref, l); } else if (DEBUG(SUFF)) { printf("already there\n"); } *************** *** 511,520 **** */ for (;;) { if (srcLn == NULL) { ! srcLn = Lst_Find(sufflist, SuffSuffIsPrefix, (ClientData)str); } else { srcLn = Lst_FindFrom(Lst_Succ(srcLn), ! SuffSuffIsPrefix, (ClientData)str); } if (srcLn == NULL) { /* --- 511,520 ---- */ for (;;) { if (srcLn == NULL) { ! srcLn = Lst_Find(sufflist, SuffSuffIsPrefix, str); } else { srcLn = Lst_FindFrom(Lst_Succ(srcLn), ! SuffSuffIsPrefix, str); } if (srcLn == NULL) { /* *************** *** 542,548 **** single = src; singleLn = srcLn; } else { ! targLn = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)str2); if (targLn != NULL) { *srcPtr = src; *targPtr = (Suff *)Lst_Datum(targLn); --- 542,548 ---- single = src; singleLn = srcLn; } else { ! targLn = Lst_Find(sufflist, SuffSuffHasNameP, str2); if (targLn != NULL) { *srcPtr = src; *targPtr = (Suff *)Lst_Datum(targLn); *************** *** 598,611 **** *t; /* target suffix */ LstNode ln; /* Node for existing transformation */ ! ln = Lst_Find(transforms, SuffGNHasNameP, (ClientData)line); if (ln == NULL) { /* * Make a new graph node for the transformation. It will be filled in * by the Parse module. */ gn = Targ_NewGN (line); ! Lst_AtEnd (transforms, (ClientData)gn); } else { /* * New specification for transformation rule. Just nuke the old list --- 598,611 ---- *t; /* target suffix */ LstNode ln; /* Node for existing transformation */ ! ln = Lst_Find(transforms, SuffGNHasNameP, line); if (ln == NULL) { /* * Make a new graph node for the transformation. It will be filled in * by the Parse module. */ gn = Targ_NewGN (line); ! Lst_AtEnd(transforms, gn); } else { /* * New specification for transformation rule. Just nuke the old list *************** *** 727,733 **** */ cp = SuffStrIsPrefix(s->name, transform->name); if (cp != (char *)NULL) { ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)cp); if (ln != NULL) { /* * Found target. Link in and return, since it can't be anything --- 727,733 ---- */ cp = SuffStrIsPrefix(s->name, transform->name); if (cp != (char *)NULL) { ! ln = Lst_Find(sufflist, SuffSuffHasNameP, cp); if (ln != NULL) { /* * Found target. Link in and return, since it can't be anything *************** *** 749,755 **** * Null-terminate the source suffix in order to find it. */ cp[1] = '\0'; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)transform->name); /* * Replace the start of the target suffix */ --- 749,755 ---- * Null-terminate the source suffix in order to find it. */ cp[1] = '\0'; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, transform->name); /* * Replace the start of the target suffix */ *************** *** 787,793 **** Suff *s; /* new suffix descriptor */ LstNode ln; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)str); if (ln == NULL) { s = (Suff *) emalloc (sizeof (Suff)); --- 787,793 ---- Suff *s; /* new suffix descriptor */ LstNode ln; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, str); if (ln == NULL) { s = (Suff *) emalloc (sizeof (Suff)); *************** *** 800,811 **** s->sNum = sNum++; s->flags = 0; ! Lst_AtEnd(sufflist, (ClientData)s); /* * Look for any existing transformations from or to this suffix. * XXX: Only do this after a Suff_ClearSuffixes? */ ! Lst_ForEach (transforms, SuffRebuildGraph, (ClientData)s); } } --- 800,811 ---- s->sNum = sNum++; s->flags = 0; ! Lst_AtEnd(sufflist, s); /* * Look for any existing transformations from or to this suffix. * XXX: Only do this after a Suff_ClearSuffixes? */ ! Lst_ForEach(transforms, SuffRebuildGraph, s); } } *************** *** 829,835 **** LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)sname); if (ln == NULL) { return (NULL); } else { --- 829,835 ---- LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, sname); if (ln == NULL) { return (NULL); } else { *************** *** 925,931 **** LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)sname); if (ln != NULL) { s = (Suff *) Lst_Datum (ln); s->flags |= SUFF_INCLUDE; --- 925,931 ---- LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, sname); if (ln != NULL) { s = (Suff *) Lst_Datum (ln); s->flags |= SUFF_INCLUDE; *************** *** 955,961 **** LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)sname); if (ln != NULL) { s = (Suff *) Lst_Datum (ln); s->flags |= SUFF_LIBRARY; --- 955,961 ---- LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, sname); if (ln != NULL) { s = (Suff *) Lst_Datum (ln); s->flags |= SUFF_LIBRARY; *************** *** 1004,1015 **** s2->suff = s; s2->children = 0; targ->children += 1; ! Lst_AtEnd(ls->l, (ClientData)s2); #ifdef DEBUG_SRC s2->cp = Lst_Init(); ! Lst_AtEnd(targ->cp, (ClientData) s2); printf("1 add %x %x to %x:", targ, s2, ls->l); ! Lst_ForEach(ls->l, PrintAddr, (ClientData) 0); printf("\n"); #endif } --- 1004,1015 ---- s2->suff = s; s2->children = 0; targ->children += 1; ! Lst_AtEnd(ls->l, s2); #ifdef DEBUG_SRC s2->cp = Lst_Init(); ! Lst_AtEnd(targ->cp, s2); printf("1 add %x %x to %x:", targ, s2, ls->l); ! Lst_ForEach(ls->l, PrintAddr, NULL); printf("\n"); #endif } *************** *** 1021,1032 **** s2->suff = s; s2->children = 0; targ->children += 1; ! Lst_AtEnd(ls->l, (ClientData)s2); #ifdef DEBUG_SRC s2->cp = Lst_Init(); ! Lst_AtEnd(targ->cp, (ClientData)s2); printf("2 add %x %x to %x:", targ, s2, ls->l); ! Lst_ForEach(ls->l, PrintAddr, (ClientData) 0); printf("\n"); #endif --- 1021,1032 ---- s2->suff = s; s2->children = 0; targ->children += 1; ! Lst_AtEnd(ls->l, s2); #ifdef DEBUG_SRC s2->cp = Lst_Init(); ! Lst_AtEnd(targ->cp, s2); printf("2 add %x %x to %x:", targ, s2, ls->l); ! Lst_ForEach(ls->l, PrintAddr, NULL); printf("\n"); #endif *************** *** 1055,1061 **** ls.s = targ; ls.l = l; ! Lst_ForEach (targ->suff->children, SuffAddSrc, (ClientData)&ls); } /*- --- 1055,1061 ---- ls.s = targ; ls.l = l; ! Lst_ForEach (targ->suff->children, SuffAddSrc, &ls); } /*- *************** *** 1083,1089 **** } #ifdef DEBUG_SRC printf("cleaning %lx: ", (unsigned long) l); ! Lst_ForEach(l, PrintAddr, (ClientData) 0); printf("\n"); #endif --- 1083,1089 ---- } #ifdef DEBUG_SRC printf("cleaning %lx: ", (unsigned long) l); ! Lst_ForEach(l, PrintAddr, NULL); printf("\n"); #endif *************** *** 1096,1102 **** free((Address)s->pref); else { #ifdef DEBUG_SRC ! LstNode ln = Lst_Member(s->parent->cp, (ClientData)s); if (ln != NULL) Lst_Remove(s->parent->cp, ln); #endif --- 1096,1102 ---- free((Address)s->pref); else { #ifdef DEBUG_SRC ! LstNode ln = Lst_Member(s->parent->cp, s); if (ln != NULL) Lst_Remove(s->parent->cp, ln); #endif *************** *** 1115,1121 **** #ifdef DEBUG_SRC else { printf("keep: [l=%x] p=%x %d: ", l, s, s->children); ! Lst_ForEach(s->cp, PrintAddr, (ClientData) 0); printf("\n"); } #endif --- 1115,1121 ---- #ifdef DEBUG_SRC else { printf("keep: [l=%x] p=%x %d: ", l, s, s->children); ! Lst_ForEach(s->cp, PrintAddr, NULL); printf("\n"); } #endif *************** *** 1180,1186 **** } SuffAddLevel (srcs, s); ! Lst_AtEnd(slst, (ClientData)s); } if (DEBUG(SUFF) && rs) { --- 1180,1186 ---- } SuffAddLevel (srcs, s); ! Lst_AtEnd(slst, s); } if (DEBUG(SUFF) && rs) { *************** *** 1235,1242 **** * The node matches the prefix ok, see if it has a known * suffix. */ ! ln = Lst_Find(sufflist, SuffSuffHasNameP, ! (ClientData)&cp[prefLen]); if (ln != NULL) { /* * It even has a known suffix, see if there's a transformation --- 1235,1241 ---- * The node matches the prefix ok, see if it has a known * suffix. */ ! ln = Lst_Find(sufflist, SuffSuffHasNameP, &cp[prefLen]); if (ln != NULL) { /* * It even has a known suffix, see if there's a transformation *************** *** 1246,1253 **** */ suff = (Suff *)Lst_Datum (ln); ! if (Lst_Member (suff->parents, ! (ClientData)targ->suff) != NULL) { /* * Hot Damn! Create a new Src structure to describe --- 1245,1251 ---- */ suff = (Suff *)Lst_Datum (ln); ! if (Lst_Member(suff->parents, targ->suff) != NULL) { /* * Hot Damn! Create a new Src structure to describe *************** *** 1266,1274 **** #ifdef DEBUG_SRC ret->cp = Lst_Init(); printf("3 add %x %x\n", targ, ret); ! Lst_AtEnd(targ->cp, (ClientData)ret); #endif ! Lst_AtEnd(slst, (ClientData)ret); if (DEBUG(SUFF)) { printf ("\tusing existing source %s\n", s->name); } --- 1264,1272 ---- #ifdef DEBUG_SRC ret->cp = Lst_Init(); printf("3 add %x %x\n", targ, ret); ! Lst_AtEnd(targ->cp, ret); #endif ! Lst_AtEnd(slst, ret); if (DEBUG(SUFF)) { printf ("\tusing existing source %s\n", s->name); } *************** *** 1313,1319 **** * New nodes effectively take the place of the child, so place them * after the child */ ! prevLN = Lst_Member(pgn->children, (ClientData)cgn); /* * First do variable expansion -- this takes precedence over --- 1311,1317 ---- * New nodes effectively take the place of the child, so place them * after the child */ ! prevLN = Lst_Member(pgn->children, cgn); /* * First do variable expansion -- this takes precedence over *************** *** 1360,1366 **** */ *cp++ = '\0'; gn = Targ_FindNode(start, TARG_CREATE); ! Lst_AtEnd(members, (ClientData)gn); while (*cp == ' ' || *cp == '\t') { cp++; } --- 1358,1364 ---- */ *cp++ = '\0'; gn = Targ_FindNode(start, TARG_CREATE); ! Lst_AtEnd(members, gn); while (*cp == ' ' || *cp == '\t') { cp++; } *************** *** 1399,1405 **** * Stuff left over -- add it to the list too */ gn = Targ_FindNode(start, TARG_CREATE); ! Lst_AtEnd(members, (ClientData)gn); } /* * Point cp back at the beginning again so the variable value --- 1397,1403 ---- * Stuff left over -- add it to the list too */ gn = Targ_FindNode(start, TARG_CREATE); ! Lst_AtEnd(members, gn); } /* * Point cp back at the beginning again so the variable value *************** *** 1414,1423 **** if (DEBUG(SUFF)) { printf("%s...", gn->name); } ! if (Lst_Member(pgn->children, (ClientData)gn) == NULL) { ! Lst_Append(pgn->children, prevLN, (ClientData)gn); prevLN = Lst_Succ(prevLN); ! Lst_AtEnd(gn->parents, (ClientData)pgn); pgn->unmade++; } } --- 1412,1421 ---- if (DEBUG(SUFF)) { printf("%s...", gn->name); } ! if (Lst_Member(pgn->children, gn) == NULL) { ! Lst_Append(pgn->children, prevLN, gn); prevLN = Lst_Succ(prevLN); ! Lst_AtEnd(gn->parents, pgn); pgn->unmade++; } } *************** *** 1431,1437 **** * Now the source is expanded, remove it from the list of children to * keep it from being processed. */ ! ln = Lst_Member(pgn->children, (ClientData)cgn); pgn->unmade--; Lst_Remove(pgn->children, ln); if (DEBUG(SUFF)) { --- 1429,1435 ---- * Now the source is expanded, remove it from the list of children to * keep it from being processed. */ ! ln = Lst_Member(pgn->children, cgn); pgn->unmade--; Lst_Remove(pgn->children, ln); if (DEBUG(SUFF)) { *************** *** 1450,1456 **** * Else use the default system search path. */ cp = cgn->name + strlen(cgn->name); ! ln = Lst_Find(sufflist, SuffSuffIsSuffixP, (ClientData)cp); if (DEBUG(SUFF)) { printf("Wildcard expanding \"%s\"...", cgn->name); --- 1448,1454 ---- * Else use the default system search path. */ cp = cgn->name + strlen(cgn->name); ! ln = Lst_Find(sufflist, SuffSuffIsSuffixP, cp); if (DEBUG(SUFF)) { printf("Wildcard expanding \"%s\"...", cgn->name); *************** *** 1487,1496 **** * If gn isn't already a child of the parent, make it so and * up the parent's count of unmade children. */ ! if (Lst_Member(pgn->children, (ClientData)gn) == NULL) { ! Lst_Append(pgn->children, prevLN, (ClientData)gn); prevLN = Lst_Succ(prevLN); ! Lst_AtEnd(gn->parents, (ClientData)pgn); pgn->unmade++; } } --- 1485,1494 ---- * If gn isn't already a child of the parent, make it so and * up the parent's count of unmade children. */ ! if (Lst_Member(pgn->children, gn) == NULL) { ! Lst_Append(pgn->children, prevLN, gn); prevLN = Lst_Succ(prevLN); ! Lst_AtEnd(gn->parents, pgn); pgn->unmade++; } } *************** *** 1504,1510 **** * Now the source is expanded, remove it from the list of children to * keep it from being processed. */ ! ln = Lst_Member(pgn->children, (ClientData)cgn); pgn->unmade--; Lst_Remove(pgn->children, ln); if (DEBUG(SUFF)) { --- 1502,1508 ---- * Now the source is expanded, remove it from the list of children to * keep it from being processed. */ ! ln = Lst_Member(pgn->children, cgn); pgn->unmade--; Lst_Remove(pgn->children, ln); if (DEBUG(SUFF)) { *************** *** 1544,1556 **** char *tname; /* Name of transformation rule */ GNode *gn; /* Node for same */ ! if (Lst_Member(tGn->children, (ClientData)sGn) == NULL) { /* * Not already linked, so form the proper links between the * target and source. */ ! Lst_AtEnd(tGn->children, (ClientData)sGn); ! Lst_AtEnd(sGn->parents, (ClientData)tGn); tGn->unmade += 1; } --- 1542,1554 ---- char *tname; /* Name of transformation rule */ GNode *gn; /* Node for same */ ! if (Lst_Member(tGn->children, sGn) == NULL) { /* * Not already linked, so form the proper links between the * target and source. */ ! Lst_AtEnd(tGn->children, sGn); ! Lst_AtEnd(sGn->parents, tGn); tGn->unmade += 1; } *************** *** 1564,1576 **** for (ln=Lst_First(sGn->cohorts); ln != NULL; ln=Lst_Succ(ln)) { gn = (GNode *)Lst_Datum(ln); ! if (Lst_Member(tGn->children, (ClientData)gn) == NULL) { /* * Not already linked, so form the proper links between the * target and source. */ ! Lst_AtEnd(tGn->children, (ClientData)gn); ! Lst_AtEnd(gn->parents, (ClientData)tGn); tGn->unmade += 1; } } --- 1562,1574 ---- for (ln=Lst_First(sGn->cohorts); ln != NULL; ln=Lst_Succ(ln)) { gn = (GNode *)Lst_Datum(ln); ! if (Lst_Member(tGn->children, gn) == NULL) { /* * Not already linked, so form the proper links between the * target and source. */ ! Lst_AtEnd(tGn->children, gn); ! Lst_AtEnd(gn->parents, tGn); tGn->unmade += 1; } } *************** *** 1579,1585 **** * Locate the transformation rule itself */ tname = str_concat(s->name, t->name, 0); ! ln = Lst_Find(transforms, SuffGNHasNameP, (ClientData)tname); free(tname); if (ln == NULL) { --- 1577,1583 ---- * Locate the transformation rule itself */ tname = str_concat(s->name, t->name, 0); ! ln = Lst_Find(transforms, SuffGNHasNameP, tname); free(tname); if (ln == NULL) { *************** *** 1611,1626 **** * Deal with wildcards and variables in any acquired sources */ ln = Lst_Succ(ln); ! if (ln != NULL) { ! Lst_ForEachFrom(tGn->children, ln, ! SuffExpandChildren, (ClientData)tGn); ! } /* * Keep track of another parent to which this beast is transformed so * the .IMPSRC variable can be set correctly for the parent. */ ! Lst_AtEnd(sGn->iParents, (ClientData)tGn); return(TRUE); } --- 1609,1622 ---- * Deal with wildcards and variables in any acquired sources */ ln = Lst_Succ(ln); ! if (ln != NULL) ! Lst_ForEachFrom(tGn->children, ln, SuffExpandChildren, tGn); /* * Keep track of another parent to which this beast is transformed so * the .IMPSRC variable can be set correctly for the parent. */ ! Lst_AtEnd(sGn->iParents, tGn); return(TRUE); } *************** *** 1682,1690 **** /* * Create the link between the two nodes right off */ ! if (Lst_Member(gn->children, (ClientData)mem) == NULL) { ! Lst_AtEnd(gn->children, (ClientData)mem); ! Lst_AtEnd(mem->parents, (ClientData)gn); gn->unmade += 1; } --- 1678,1686 ---- /* * Create the link between the two nodes right off */ ! if (Lst_Member(gn->children, mem) == NULL) { ! Lst_AtEnd(gn->children, mem); ! Lst_AtEnd(mem->parents, gn); gn->unmade += 1; } *************** *** 1864,1870 **** /* * Record the target so we can nuke it */ ! Lst_AtEnd(targs, (ClientData)targ); /* * Search from this suffix's successor... --- 1860,1866 ---- /* * Record the target so we can nuke it */ ! Lst_AtEnd(targs, targ); /* * Search from this suffix's successor... *************** *** 1906,1912 **** if (DEBUG(SUFF)) printf("adding suffix rules\n"); ! Lst_AtEnd(targs, (ClientData)targ); } /* --- 1902,1908 ---- if (DEBUG(SUFF)) printf("adding suffix rules\n"); ! Lst_AtEnd(targs, targ); } /* *************** *** 1949,1955 **** * Now we've got the important local variables set, expand any sources * that still contain variables or wildcards in their names. */ ! Lst_ForEach(gn->children, SuffExpandChildren, (ClientData)gn); if (targ == NULL) { if (DEBUG(SUFF)) { --- 1945,1951 ---- * Now we've got the important local variables set, expand any sources * that still contain variables or wildcards in their names. */ ! Lst_ForEach(gn->children, SuffExpandChildren, gn); if (targ == NULL) { if (DEBUG(SUFF)) { *************** *** 2042,2049 **** * up to, but not including, the parent node. */ while (bottom && bottom->parent != NULL) { ! if (Lst_Member(slst, (ClientData) bottom) == NULL) { ! Lst_AtEnd(slst, (ClientData) bottom); } bottom = bottom->parent; } --- 2038,2045 ---- * up to, but not including, the parent node. */ while (bottom && bottom->parent != NULL) { ! if (Lst_Member(slst, bottom) == NULL) { ! Lst_AtEnd(slst, bottom); } bottom = bottom->parent; } *************** *** 2118,2125 **** */ sfnd_return: if (bottom) ! if (Lst_Member(slst, (ClientData) bottom) == NULL) ! Lst_AtEnd(slst, (ClientData) bottom); while (SuffRemoveSrc(srcs) || SuffRemoveSrc(targs)) continue; --- 2114,2121 ---- */ sfnd_return: if (bottom) ! if (Lst_Member(slst, bottom) == NULL) ! Lst_AtEnd(slst, bottom); while (SuffRemoveSrc(srcs) || SuffRemoveSrc(targs)) continue; *************** *** 2200,2206 **** LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)LIBSUFF); if (ln != NULL) { gn->suffix = s = (Suff *) Lst_Datum (ln); Arch_FindLib (gn, s->searchPath); --- 2196,2202 ---- LstNode ln; Suff *s; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, LIBSUFF); if (ln != NULL) { gn->suffix = s = (Suff *) Lst_Datum (ln); Arch_FindLib (gn, s->searchPath); *************** *** 2243,2249 **** Suff *s; LstNode ln; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, (ClientData)name); if (ln != NULL) { s = (Suff *)Lst_Datum(ln); if (suffNull != (Suff *)NULL) { --- 2239,2245 ---- Suff *s; LstNode ln; ! ln = Lst_Find(sufflist, SuffSuffHasNameP, name); if (ln != NULL) { s = (Suff *)Lst_Datum(ln); if (suffNull != (Suff *)NULL) { *************** *** 2373,2382 **** } fputc ('\n', stdout); printf ("#\tTo: "); ! Lst_ForEach (s->parents, SuffPrintName, (ClientData)0); fputc ('\n', stdout); printf ("#\tFrom: "); ! Lst_ForEach (s->children, SuffPrintName, (ClientData)0); fputc ('\n', stdout); printf ("#\tSearch Path: "); Dir_PrintPath (s->searchPath); --- 2369,2378 ---- } fputc ('\n', stdout); printf ("#\tTo: "); ! Lst_ForEach(s->parents, SuffPrintName, NULL); fputc ('\n', stdout); printf ("#\tFrom: "); ! Lst_ForEach(s->children, SuffPrintName, NULL); fputc ('\n', stdout); printf ("#\tSearch Path: "); Dir_PrintPath (s->searchPath); *************** *** 2394,2400 **** printf ("%-16s: ", t->name); Targ_PrintType (t->type); fputc ('\n', stdout); ! Lst_ForEach (t->commands, Targ_PrintCmd, (ClientData)0); fputc ('\n', stdout); return(dummy ? 0 : 0); } --- 2390,2396 ---- printf ("%-16s: ", t->name); Targ_PrintType (t->type); fputc ('\n', stdout); ! Lst_ForEach(t->commands, Targ_PrintCmd, NULL); fputc ('\n', stdout); return(dummy ? 0 : 0); } *************** *** 2403,2410 **** Suff_PrintAll() { printf ("#*** Suffixes:\n"); ! Lst_ForEach (sufflist, SuffPrintSuff, (ClientData)0); printf ("#*** Transformations:\n"); ! Lst_ForEach (transforms, SuffPrintTrans, (ClientData)0); } --- 2399,2406 ---- Suff_PrintAll() { printf ("#*** Suffixes:\n"); ! Lst_ForEach(sufflist, SuffPrintSuff, NULL); printf ("#*** Transformations:\n"); ! Lst_ForEach(transforms, SuffPrintTrans, NULL); }