Prevented bug when interpreting MBR partition entry > 1 TB. Coverity CID 28764.

master
Thomas Schmitt 7 years ago
parent 85424a0f31
commit 77639ca1cd
  1. 6
      xorriso/write_run.c
  2. 2
      xorriso/xorriso_timestamp.h

@ -455,8 +455,10 @@ int Xorriso_set_system_area(struct XorrisO *xorriso, struct burn_drive *drive,
system_area_options= xorriso->patch_system_area;
/* Check whether partition 1 ends at image end */;
ub= (unsigned char *) buf;
hd_lba= (ub[454] | (ub[455] << 8) | (ub[456] << 16) | (ub[457] << 24)) +
(ub[458] | (ub[459] << 8) | (ub[460] << 16) | (ub[461] << 24));
hd_lba= (ub[454] | (ub[455] << 8) | (ub[456] << 16) |
(((unsigned int) ub[457]) << 24)) +
(ub[458] | (ub[459] << 8) | (ub[460] << 16) |
(((unsigned int) ub[461]) << 24));
iso_lba= -1;
ret= isoburn_disc_get_msc1(drive, &start_lba);

@ -1 +1 @@
#define Xorriso_timestamP "2015.11.04.094803"
#define Xorriso_timestamP "2015.11.04.100839"

Loading…
Cancel
Save