Salut a tous
j' ai une structure du type Noeud
typedef struct Noeud{
char * traduction;
char * origine ;
struct Noeud * gauche ;
struct Noeud * droit;
} Noeud;
Dans une fonction ou je cree un nouveau noeud,
je n'arrive pas a initialiser les char*
Noeud * nouveau;
nouveau->origine = (char*)malloc( (sizeof(char)));
strcpy(nouveau->origine , tmp[0]);
nouveau->traduction = (char*)malloc(sizeof(char));
strcpy(nouveau->traduction , tmp[LANGUE_CHOISIE]);
Mon tableau de char * tmp n'est pas un probleme, il fonctionne tres bien.
Merci a tous
