ThibaultLasou / CustomShell

Projet Systèmes - ET3 Polytech Paris-Sud
0 stars 0 forks source link

FG - BG - WAIT #7

Open ThibaultLasou opened 8 years ago

ThibaultLasou commented 8 years ago

FG : on attend que le programme s'arrête avant de relire stdin BG : le programme s'exécute en arrière plan mais affiche dans stdout (si pas de redir...) WAIT : on lit stdin à la fin du programme (on peut donc taper une commande mais elle ne sera exécutée qu'à la fin du programme)

ThibaultLasou commented 8 years ago

struct sigaction int_handler = {.sa_handler=handle_int}; //handle_int is the callback function int_handler.sa_flags = SA_NOCLDSTOP | SA_NOCLDWAIT; sigaction(SIGINT,&int_handler,0);

Gérer les signaux (CTRL + CHoOoSE)

ThibaultLasou commented 8 years ago

Mika : Faudra que tu configure ton waitpid (les options seront important, WCONTINUED !) et que tu envoie le signal SIGCONT à l'enfant