* increments the string reference count.
*/
-int string_check(id)
+struct string *string_check(id)
int id;
{
register struct string *s;
s = (struct string *) hash_lookup(strings, id);
if (s == NULL)
- return(0);
+ return(s);
s->refc++;
- return(1);
+ return(s);
}
##{
printf("Phase 3 - Finding unused objects\n");
- dprintf("Checking machines...\n");
- hash_step(machines, noclu_mach_check, NULL);
+ if (warn) {
+ dprintf("Checking machines...\n");
+ hash_step(machines, noclu_mach_check, NULL);
- dprintf("Checking lists...\n");
- hash_step(lists, empty_list_check, NULL);
+ dprintf("Checking lists...\n");
+ hash_step(lists, empty_list_check, NULL);
+ }
dprintf("Checking strings...\n");
hash_step(strings, unref_string_check, NULL);