0

I'm writing a basic shell to give out as a class assignment, it works fine on linux but I'm having issues with recapturing control of the terminal when a child process exits on OSX.

I tried making a call to tcsetpgrp(STDERR_FILENO,getpgrp()); but it is interrupted by both SIGTTIN and SIGTTOU. If I ignore the signals, the terminal becomes inaccessible to reading or writing.

Thanks.

shaananc
  • 67
  • 6

1 Answers1

0

Solved. The question wasn't too excellent.

The answer was that I needed to put the child in it's own process group and make it the session leader.

shaananc
  • 67
  • 6