|
|
|
@ -52,7 +52,7 @@ Precedence *loadPrec(int *tmax, int *tlog)
|
|
|
|
|
}
|
|
|
|
|
tabP = s;
|
|
|
|
|
}
|
|
|
|
|
fscanf(prec, "%s%s", tabP[tlog-1].travauxPrec, tabP[tlog-1].travauxSucc);
|
|
|
|
|
fscanf(prec, "%s%s", tabP[*tlog-1].travauxPrec, tabP[*tlog-1].travauxSucc);
|
|
|
|
|
(*tlog)++;
|
|
|
|
|
}
|
|
|
|
|
fclose(prec);
|
|
|
|
@ -63,7 +63,13 @@ Tache **chargeTaches(Offre *tabTravaux[])
|
|
|
|
|
{
|
|
|
|
|
Precedence *prec;
|
|
|
|
|
int i, tmaxPrec=5, tlogPrec;
|
|
|
|
|
Tache *t, *tabTache[8];
|
|
|
|
|
Tache *t, **tabTache;
|
|
|
|
|
tabTache = Tache(**)malloc(8*sizeof(Tache *));
|
|
|
|
|
if (tabTache == NULL)
|
|
|
|
|
{
|
|
|
|
|
printf("\033[0;31mErreur: \033[0mmalloc tableau tache\n");
|
|
|
|
|
exit(1);
|
|
|
|
|
}
|
|
|
|
|
for (i=0; i<tmaxTravaux; i++)
|
|
|
|
|
{
|
|
|
|
|
t=(Tache *)malloc(sizeof(Tache));
|
|
|
|
|