But when I run again the library error 2:10: fatal error: ospace/unix.h: No such file or directory Can you help me? Thank you so much <3
with topic: Write a C program that illustrates suspending and resuming processes using signals
I have the following code:
#include <stdio.h>
#include <ospace/unix.h>
int child_function()
{
while (true) // Loop forever.
{
Printf("Child loop\n");
os_this_process::sleep( 1 );
}
return 0; // Will never execute.
}
int main()
{
os_unix_toolkit initialize;
os_process child ( child function ); // Spawn child.
os_this_process::sleep( 4 );
printf("child.suspend()\n");
child.suspend();
printf("Parent sleeps for 4 seconds\n");
os_this_process::sleep (4);
printf("child.resume()");
child.resume();
os_this_process::sleep (4);
printf("child.terminate()");
child.terminate();
printf("Parent finished");
return 0;
}
But when I run again the library error
2:10: fatal error: ospace/unix.h: No such file or directory
Can you help me? Thank you so much <3
Step by step
Solved in 2 steps