The lines: if (instance == PRIMARY_GPT) hdr_offset = block_size; else { hdr_offset = lseek64(fd, 0, SEEK_END) - block_size; } if (hdr_offset < 0) { fprintf(stderr, "%s: Failed to get gpt header offset\n", __func__); goto error; } are error checked. But previously hdr_offset could never be less than zero because it was unsigned.merge-requests/7/head
parent
e705c38010
commit
843aa92266
Loading…
Reference in new issue