You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#!/bin/bash
db_dir="./"
db_file="$db_dir/test.db"if [ !-f"$db_file" ];thenecho"$db_file"""fi
tables="val1 val2 val3 val4 val5 val6 val7"fortablein$tables;doecho"$db_file""test $table 11111"if [ $?-eq 0 ];then# Step 3: Create table if it does not existcase$tablein"val1")
echo"$db_file""\ TEST TEST \ TEST TEST \ TEST TEST \ TEST TEST \ TEST TEST \ TEST TEST \ TEST TEST \ TEST TEST \ TEST "echo"$db_file""\ TEST TEST \ TEST TEST \ TEST TEST \ BEGIN \ TEST "
;;
"val2")
echo"$db_file""\ TEST \ TEST \ TEST "echo"$db_file""TEST"echo"$db_file""\ TEST \ TEST \ TEST \ TEST \ TEST \ TEST \ TEST \ TEST"
;;
"val3")
echo"$db_file""\ TEST \ TEST \ TEST \ TEST \ TEST \ TEST"echo"$db_file""\ TEST \ TEST "
;;
"val4")
echo"$db_file""\ TEST \ TEST \ TEST "echo"$db_file""\ TEST \ TEST \ TEST"
;;
"val5")
echo"$db_file""\ TEST \ TEST \ TEST"echo"$db_file""\ TEST \ TEST \ TEST"
;;
"val6")
echo"$db_file""\ TEST \ TEST "echo"$db_file""\ TEST TEST TEST " \
;;
"val7")
echo"$db_file""\ TEST \ TEST \ TEST \ TEST"
;;
esacfidone
Maybe this is a problem about freeing an incorrect address.
} elseif (!strcmp(s, "case")) {
if (!(TT.ff->blk->fvar=expand_one_arg(ss, NO_NULL))) break;
if (ss!=TT.ff->blk->fvar)
push_arg(&TT.ff->blk->fdelete, TT.ff->blk->fvar);
}
In the run_lines function, if the case feature is encountered, TT.ff->blk->fvar will be put into the link list TT.ff->blk->fdelete. When the case is over, the pop_block function is called to free the link list data.
However, the data stored in TT.ff->blk->fvar is not a correct address (it's an address returned by getvar function plusing offset). So toybox crashed in free stage.
The text was updated successfully, but these errors were encountered:
the test shell scripts are shown as blew:
Maybe this is a problem about freeing an incorrect address.
In the
run_lines
function, if thecase
feature is encountered,TT.ff->blk->fvar
will be put into the link listTT.ff->blk->fdelete
. When the case is over, thepop_block
function is called to free the link list data.However, the data stored in
TT.ff->blk->fvar
is not a correct address (it's an address returned bygetvar
function plusing offset). Sotoybox
crashed in free stage.The text was updated successfully, but these errors were encountered: