--- rpl/src/gestion_variables.c 2015/01/05 13:12:32 1.85 +++ rpl/src/gestion_variables.c 2015/01/29 09:33:41 1.89 @@ -1,6 +1,6 @@ /* ================================================================================ - RPL/2 (R) version 4.1.19 + RPL/2 (R) version 4.1.20 Copyright (C) 1989-2015 Dr. BERTRAND Joël This file is part of RPL/2. @@ -2010,6 +2010,7 @@ liste_variables_locales(struct_processus (*(*l_variable_statique).variable).variable_statique; tableau[position].variable_partagee.pointeur = NULL; tableau[position].variable_masquee = d_vrai; + tableau[position].mutex = NULL; position++; } @@ -2235,14 +2236,18 @@ copie_arbre_variables(struct_processus * s_variable = (*((struct_variable *) (*l_element_courant).donnee)); - if ((s_variable.nom = strdup((*((struct_variable *) - (*l_element_courant).donnee)).nom)) == NULL) + if ((s_variable.nom = malloc((strlen((*((struct_variable *) + (*l_element_courant).donnee)).nom) + 1) * + sizeof(unsigned char))) == NULL) { (*s_nouvel_etat_processus).erreur_systeme = d_es_allocation_memoire; return; } + strcpy(s_variable.nom, (*((struct_variable *) + (*l_element_courant).donnee)).nom); + if ((s_variable.objet = copie_objet(s_nouvel_etat_processus, (*((struct_variable *) (*l_element_courant).donnee)) .objet, 'P')) == NULL) @@ -2448,7 +2453,7 @@ copie_arbre_variables(struct_processus * */ /* - * Caractères autorisés dans les instructions + * Caractères autorisés dans les variables * * A B C D E F G H I J K L M N O P Q R S T U V W X Y Z * a b c d e f g h i j k l m n o p q r s t u v w x y z