version 1.102, 2018/12/24 15:56:41
|
version 1.115, 2025/04/15 10:17:58
|
Line 1
|
Line 1
|
/* |
/* |
================================================================================ |
================================================================================ |
RPL/2 (R) version 4.1.30 |
RPL/2 (R) version 4.1.36 |
Copyright (C) 1989-2018 Dr. BERTRAND Joël |
Copyright (C) 1989-2025 Dr. BERTRAND Joël |
|
|
This file is part of RPL/2. |
This file is part of RPL/2. |
|
|
Line 134 sequenceur(struct_processus *s_etat_proc
|
Line 134 sequenceur(struct_processus *s_etat_proc
|
*/ |
*/ |
|
|
action.sa_handler = SIG_IGN; |
action.sa_handler = SIG_IGN; |
action.sa_flags = SA_NODEFER | SA_ONSTACK; |
action.sa_flags = 0; |
|
|
(*s_etat_processus).execution_pas_suivant = d_faux; |
(*s_etat_processus).execution_pas_suivant = d_faux; |
(*s_etat_processus).traitement_instruction_halt = d_vrai; |
(*s_etat_processus).traitement_instruction_halt = d_vrai; |
Line 162 sequenceur(struct_processus *s_etat_proc
|
Line 162 sequenceur(struct_processus *s_etat_proc
|
fflush(stdout); |
fflush(stdout); |
} |
} |
|
|
|
if (pthread_mutex_lock(&mutex_sigaction) != 0) |
|
{ |
|
(*s_etat_processus).erreur_systeme = d_es_processus; |
|
return(d_erreur); |
|
} |
|
|
if (sigaction(SIGINT, &action, &action_defaut) != 0) |
if (sigaction(SIGINT, &action, &action_defaut) != 0) |
{ |
{ |
|
pthread_mutex_unlock(&mutex_sigaction); |
(*s_etat_processus).erreur_systeme = d_es_signal; |
(*s_etat_processus).erreur_systeme = d_es_signal; |
return(d_erreur); |
return(d_erreur); |
} |
} |
|
|
if (sigaction(SIGTSTP, &action, &action_defaut2) != 0) |
if (sigaction(SIGTSTP, &action, &action_defaut2) != 0) |
{ |
{ |
|
pthread_mutex_unlock(&mutex_sigaction); |
(*s_etat_processus).erreur_systeme = d_es_signal; |
(*s_etat_processus).erreur_systeme = d_es_signal; |
return(d_erreur); |
return(d_erreur); |
} |
} |
Line 203 sequenceur(struct_processus *s_etat_proc
|
Line 211 sequenceur(struct_processus *s_etat_proc
|
(*s_etat_processus).localisation, d_locale)) |
(*s_etat_processus).localisation, d_locale)) |
== NULL) |
== NULL) |
{ |
{ |
|
pthread_mutex_unlock(&mutex_sigaction); |
free((*s_etat_processus).instruction_courante); |
free((*s_etat_processus).instruction_courante); |
return(d_erreur); |
return(d_erreur); |
} |
} |
Line 212 sequenceur(struct_processus *s_etat_proc
|
Line 221 sequenceur(struct_processus *s_etat_proc
|
|
|
if ((ligne = compactage(s_etat_processus, ligne)) == NULL) |
if ((ligne = compactage(s_etat_processus, ligne)) == NULL) |
{ |
{ |
|
pthread_mutex_unlock(&mutex_sigaction); |
(*s_etat_processus).erreur_systeme = |
(*s_etat_processus).erreur_systeme = |
d_es_allocation_memoire; |
d_es_allocation_memoire; |
return(d_erreur); |
return(d_erreur); |
Line 220 sequenceur(struct_processus *s_etat_proc
|
Line 230 sequenceur(struct_processus *s_etat_proc
|
|
|
if (sigaction(SIGINT, &action_defaut, NULL) != 0) |
if (sigaction(SIGINT, &action_defaut, NULL) != 0) |
{ |
{ |
|
pthread_mutex_unlock(&mutex_sigaction); |
(*s_etat_processus).erreur_systeme = d_es_signal; |
(*s_etat_processus).erreur_systeme = d_es_signal; |
return(d_erreur); |
return(d_erreur); |
} |
} |
|
|
if (sigaction(SIGTSTP, &action_defaut2, NULL) != 0) |
if (sigaction(SIGTSTP, &action_defaut2, NULL) != 0) |
{ |
{ |
|
pthread_mutex_unlock(&mutex_sigaction); |
(*s_etat_processus).erreur_systeme = d_es_signal; |
(*s_etat_processus).erreur_systeme = d_es_signal; |
return(d_erreur); |
return(d_erreur); |
} |
} |
|
|
|
if (pthread_mutex_unlock(&mutex_sigaction) != 0) |
|
{ |
|
(*s_etat_processus).erreur_systeme = d_es_processus; |
|
return(d_erreur); |
|
} |
|
|
if (ligne == NULL) |
if (ligne == NULL) |
{ |
{ |
if ((ligne = (unsigned char *) malloc(6 * |
if ((ligne = (unsigned char *) malloc(6 * |
Line 742 sequenceur(struct_processus *s_etat_proc
|
Line 760 sequenceur(struct_processus *s_etat_proc
|
} |
} |
} |
} |
|
|
|
(*s_etat_processus).debug_programme = d_faux; |
|
|
(*(*s_etat_processus).l_base_pile_systeme) |
(*(*s_etat_processus).l_base_pile_systeme) |
.adresse_retour = (*s_etat_processus) |
.adresse_retour = (*s_etat_processus) |
.position_courante; |
.position_courante; |