Browse Source

Bug fix: -modesty_on_drive properties timeout_sec, min_usec, max_usec read wrong numbers from the parameter text

master
Thomas Schmitt 6 years ago
parent
commit
7fe3670181
  1. 19
      xorriso/opts_i_o.c
  2. 2
      xorriso/xorriso_timestamp.h

19
xorriso/opts_i_o.c

@ -860,25 +860,28 @@ bad_percent:;
ppt= cpt + 12;
set_min= 0;
goto set_size_percent;
} else if(l >= 8 && strncmp(cpt, "min_usec=", 8) == 0) {
ppt= cpt + 8;
} else if(l >= 9 && strncmp(cpt, "min_usec=", 9) == 0) {
ppt= cpt + 9;
set_min= 1;
set_sec:;
num= -1;
sscanf(ppt, "%d", &num);
if(num < 0)
num= 0;
if(set_min == 1)
if(set_min == 2)
xorriso->max_buffer_usec= num;
else if(set_min == 1)
xorriso->min_buffer_usec= num;
else if(set_min == 0)
xorriso->max_buffer_percent= num;
else
xorriso->buffer_timeout_sec= num;
} else if(l >= 8 && strncmp(cpt, "max_usec=", 8) == 0) {
ppt= cpt + 8;
set_min= 0;
} else if(l >= 9 && strncmp(cpt, "max_usec=", 9) == 0) {
ppt= cpt + 9;
set_min= 2;
goto set_sec;
} else if(l >= 11 && strncmp(cpt, "timeout_sec=", 11) == 0) {
ppt= cpt + 11;
} else if(l >= 12 && strncmp(cpt, "timeout_sec=", 12) == 0) {
ppt= cpt + 12;
set_min= -1;
goto set_sec;
} else {

2
xorriso/xorriso_timestamp.h

@ -1 +1 @@
#define Xorriso_timestamP "2016.02.27.170008"
#define Xorriso_timestamP "2016.03.01.141456"

Loading…
Cancel
Save