Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/label/src/gpt.c

    rb33d140 rdeacc58d  
    9999        uint8_t *etable[2];
    100100        size_t bsize;
    101         aoff64_t nblocks;
    102101        uint32_t num_entries;
    103102        uint32_t esize;
     
    124123        }
    125124
    126         rc = bd->ops->get_nblocks(bd->arg, &nblocks);
    127         if (rc != EOK) {
    128                 rc = EIO;
    129                 goto error;
    130         }
    131 
    132125        if (bsize < 512 || (bsize % 512) != 0) {
    133126                rc = EINVAL;
     
    154147
    155148        h1ba = uint64_t_le2host(gpt_hdr[0]->alternate_lba);
    156 
    157         if (h1ba >= nblocks) {
    158                 rc = EINVAL;
    159                 goto error;
    160         }
    161149
    162150        rc = bd->ops->read(bd->arg, h1ba, 1, gpt_hdr[1]);
Note: See TracChangeset for help on using the changeset viewer.