diff --git a/source/chargEtSauvFich.c b/source/chargEtSauvFich.c index a64acc3..f9ff82d 100644 --- a/source/chargEtSauvFich.c +++ b/source/chargEtSauvFich.c @@ -27,6 +27,8 @@ VilleIut ** chargeIutDon(char nomFichier[], int * nbIut, int * nbMax) *nbMax = 5; + + i = 0; while (!feof(fichier)) { @@ -45,6 +47,7 @@ VilleIut ** chargeIutDon(char nomFichier[], int * nbIut, int * nbMax) fclose(fichier); fusionIut(tIut, nbIut); + return tIut; } diff --git a/source/sae.c b/source/sae.c index 37c4030..edb57c4 100644 --- a/source/sae.c +++ b/source/sae.c @@ -81,10 +81,8 @@ Log * chargementLog(char * nomFichier, int * nbLog) } fscanf(fichier, "%s %s %s", tLog[i].utilisateur, tLog[i].mdp, tLog[i].status); - printf("%s\n", tLog[i].status); i++; } - *nbLog = i; return tLog; }