Make output match the real lsmod -- print (autoclean) type
stuff first not last. -Erik
This commit is contained in:
parent
d160a27ec1
commit
afeb96547f
12
lsmod.c
12
lsmod.c
@ -103,12 +103,6 @@ extern int lsmod_main(int argc, char **argv)
|
|||||||
deps = xrealloc(deps, bufsize = count);
|
deps = xrealloc(deps, bufsize = count);
|
||||||
}
|
}
|
||||||
printf("%-20s%8lu%4ld ", mn, info.size, info.usecount);
|
printf("%-20s%8lu%4ld ", mn, info.size, info.usecount);
|
||||||
if (count) printf("[");
|
|
||||||
for (j = 0, dn = deps; j < count; dn += strlen(dn) + 1, j++) {
|
|
||||||
printf("%s%s", dn, (j==count-1)? "":" ");
|
|
||||||
}
|
|
||||||
if (count) printf("] ");
|
|
||||||
|
|
||||||
if (info.flags & NEW_MOD_DELETED)
|
if (info.flags & NEW_MOD_DELETED)
|
||||||
printf("(deleted)");
|
printf("(deleted)");
|
||||||
else if (info.flags & NEW_MOD_INITIALIZING)
|
else if (info.flags & NEW_MOD_INITIALIZING)
|
||||||
@ -121,6 +115,12 @@ extern int lsmod_main(int argc, char **argv)
|
|||||||
if (!(info.flags & NEW_MOD_USED_ONCE))
|
if (!(info.flags & NEW_MOD_USED_ONCE))
|
||||||
printf("(unused)");
|
printf("(unused)");
|
||||||
}
|
}
|
||||||
|
if (count) printf("[");
|
||||||
|
for (j = 0, dn = deps; j < count; dn += strlen(dn) + 1, j++) {
|
||||||
|
printf("%s%s", dn, (j==count-1)? "":" ");
|
||||||
|
}
|
||||||
|
if (count) printf("] ");
|
||||||
|
|
||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -103,12 +103,6 @@ extern int lsmod_main(int argc, char **argv)
|
|||||||
deps = xrealloc(deps, bufsize = count);
|
deps = xrealloc(deps, bufsize = count);
|
||||||
}
|
}
|
||||||
printf("%-20s%8lu%4ld ", mn, info.size, info.usecount);
|
printf("%-20s%8lu%4ld ", mn, info.size, info.usecount);
|
||||||
if (count) printf("[");
|
|
||||||
for (j = 0, dn = deps; j < count; dn += strlen(dn) + 1, j++) {
|
|
||||||
printf("%s%s", dn, (j==count-1)? "":" ");
|
|
||||||
}
|
|
||||||
if (count) printf("] ");
|
|
||||||
|
|
||||||
if (info.flags & NEW_MOD_DELETED)
|
if (info.flags & NEW_MOD_DELETED)
|
||||||
printf("(deleted)");
|
printf("(deleted)");
|
||||||
else if (info.flags & NEW_MOD_INITIALIZING)
|
else if (info.flags & NEW_MOD_INITIALIZING)
|
||||||
@ -121,6 +115,12 @@ extern int lsmod_main(int argc, char **argv)
|
|||||||
if (!(info.flags & NEW_MOD_USED_ONCE))
|
if (!(info.flags & NEW_MOD_USED_ONCE))
|
||||||
printf("(unused)");
|
printf("(unused)");
|
||||||
}
|
}
|
||||||
|
if (count) printf("[");
|
||||||
|
for (j = 0, dn = deps; j < count; dn += strlen(dn) + 1, j++) {
|
||||||
|
printf("%s%s", dn, (j==count-1)? "":" ");
|
||||||
|
}
|
||||||
|
if (count) printf("] ");
|
||||||
|
|
||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user