| Summary: | sed: jumps are not handled correctly inside command groups | ||
|---|---|---|---|
| Product: | Busybox | Reporter: | steffen1956 |
| Component: | Standard Compliance | Assignee: | unassigned |
| Status: | NEW --- | ||
| Severity: | normal | CC: | busybox-cvs |
| Priority: | P5 | ||
| Version: | 1.19.x | ||
| Target Milestone: | --- | ||
| Hardware: | Other | ||
| OS: | Linux | ||
| Host: | Target: | ||
| Build: | |||
Hi! BusyBox' sed has problems when a command ground "{...}" ends with a jump statement "b". I tried the following examples both in my local BusyBox 1.19.4 and in the VM (http://busybox.net/live_bbox/live_bbox.html) with version 1.20.0. Both examples work without any problems when executed by GNU sed. example 1 (jump with label) --------------------------- / # echo 'a > b > c > d' | sed -ne ':a /^b/ {n;p;b a}' sed: unterminated { example 2 (jump w/o label) -------------------------- / # echo 'a > b > c > d' | sed -ne '/^b/ {x;p;b}' -e 'h' sed: unterminated { Adding a semicolon before the closing brace is a workaround in both cases. / # echo 'a > b > c > d' | sed -ne '/^b/ {x;p;b;}' -e 'h' a