1) Moved tprintf and related functions to their own file in common/libc/printf/tprintf.c.
This file is included by both libc and hostcompat. 2) Changed printf -> tprintf in all testbin programs
This commit is contained in:
@@ -169,7 +169,7 @@ spawn(int njobs)
|
||||
semcreate("1", &s1);
|
||||
semcreate("2", &s2);
|
||||
|
||||
printf("Forking %d child processes...\n", njobs);
|
||||
tprintf("Forking %d child processes...\n", njobs);
|
||||
|
||||
for (i=0; i<njobs; i++) {
|
||||
pids[i] = fork();
|
||||
@@ -193,9 +193,9 @@ spawn(int njobs)
|
||||
|
||||
semopen(&s1);
|
||||
semopen(&s2);
|
||||
printf("Waiting for fork...\n");
|
||||
tprintf("Waiting for fork...\n");
|
||||
semP(&s1, njobs);
|
||||
printf("Starting the execs...\n");
|
||||
tprintf("Starting the execs...\n");
|
||||
semV(&s2, njobs);
|
||||
|
||||
failed = 0;
|
||||
@@ -219,7 +219,7 @@ spawn(int njobs)
|
||||
warnx("%d children failed", failed);
|
||||
}
|
||||
else {
|
||||
printf("Succeeded\n");
|
||||
tprintf("Succeeded\n");
|
||||
}
|
||||
|
||||
semclose(&s1);
|
||||
|
Reference in New Issue
Block a user