Reacted on compiler warning of Debian i386 buildd

This commit is contained in:
Thomas Schmitt 2021-09-04 10:00:20 +02:00
parent 562247b74f
commit 8a11dc6224
2 changed files with 3 additions and 3 deletions

View File

@ -305,9 +305,9 @@ int Xorriso_option_print(struct XorrisO *xorriso, char *text, int flag)
maxl= sizeof(xorriso->mark_text);
else
maxl= sizeof(xorriso->result_line);
if(l >= maxl) {
if(l > maxl - 2) {
sprintf(xorriso->info_text, "Output text too long for -print%s(%d > %d)",
mode == 1 ? "_info" : mode == 2 ? "_mark" : "", l, maxl);
mode == 1 ? "_info" : mode == 2 ? "_mark" : "", l, maxl - 2);
Xorriso_msgs_submit(xorriso, 0, xorriso->info_text, 0, "WARNING", 0);
return(0);
}

View File

@ -1 +1 @@
#define Xorriso_timestamP "2021.08.30.145223"
#define Xorriso_timestamP "2021.09.04.075955"