Bug 7598

Summary: Crash executing code - Fuzz Testing
Product: Busybox Reporter: Fernando Muñoz <fernando>
Component: OtherAssignee: unassigned
Status: RESOLVED FIXED    
Severity: normal CC: busybox-cvs
Priority: P5    
Version: 1.21.x   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Host: Target:
Build:

Description Fernando Muñoz 2014-11-06 20:22:25 UTC
The following code makes busybox segfault:

export R="";
echo "${R:$((${R}-1)):1}"

I don't have a busybox debug version at the moment.

$ gdb busybox

...

(gdb) run  sh -c 'export R="";echo "${R:$((${R}-1)):1}"'^C
Starting program: /bin/busybox sh -c 'export R="";echo "${R:$((${R}-1)):1}"'^C

Program received signal SIGSEGV, Segmentation fault.
0x0000000000422825 in ?? ()
Comment 1 Denys Vlasenko 2014-11-17 19:28:09 UTC
Fixed in git.