]> git.llucax.com Git - z.facultad/75.06/emufs.git/blobdiff - emufs/fsc.c
Small change al fix de Luca en emufs_fsc_agregar_gap. No need to break the while...
[z.facultad/75.06/emufs.git] / emufs / fsc.c
index 95d378aa5ad5f8d0f0903beca7a694c5b97c574a..75202826c0a11debd6a27a30063750bd3bd8724b 100644 (file)
@@ -125,10 +125,7 @@ int emufs_fsc_agregar_gap(EMUFS *emu, EMUFS_OFFSET marker, EMUFS_FREE freespace)
                /* Busco el gap que sucede a este */
                fseek(f_fsc,0,SEEK_SET);
                while (!feof(f_fsc)) {
-                       if (fread(&gap_aux,sizeof(EMUFS_FSC),1,f_fsc) != 1) {
-                               if (feof(f_fsc)) break;
-                               PERR("error al leer archivo fsc");
-                       }
+                       if (fread(&gap_aux,sizeof(EMUFS_FSC),1,f_fsc) != 1) continue;
                        if (gap_aux.marker > gap_new.marker) {
                                found = 1;
                                break;
@@ -570,4 +567,3 @@ EMUFS_BLOCK_ID emufs_fsc_get_num_blocks(EMUFS* efs)
        fclose(f_fsc);
        return cant;
 }
-