1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Awk "system" command bug in Tomato 1.23

Discussion in 'Tomato Firmware' started by tunasashimi, Apr 28, 2009.

  1. tunasashimi

    tunasashimi LI Guru Member

    From the bash prompt:

    # echo | awk '{print "Current:";system("pwd")}'
    should give you the current directory - and does so on Tomato 1.11

    But not so on Tomato 1.23. - it does not even execute the awk script half the time.

    Can anybody confirm this, offer advice, or report this to the maintainer?

  2. tunasashimi

    tunasashimi LI Guru Member


    Correction: 1.23 does not execute the awk script most of the time, when it reads standard input:
    awk '{print "Current:";system("pwd")}'
    Then press ENTER a few times - you should not get a bash prompt before you press Ctrl+C!
    Works 100% everytime on Tomato 1.11
  3. averylinden

    averylinden Addicted to LI Member

    I can confirm this for tomato 1.23. But it's likely a busybox bug and not a tomato bug per se.
  4. mstombs

    mstombs Network Guru Member

    This is also a bug in Tomato 1.22

    BusyBox v1.12.2 (2008-11-16 03:35:24 PST) built-in shell (ash)
    I've seen symptoms for a while - it seems that using command recall using "up arrow" and "enter" is not reliable - but difficult to report because it doesn't seem 100% predictable.


    There's a lot of activity on http://www.busybox.net/ there are potential fixes to option passing and awk - need to see if problem goes away in latest stable 1.13.4 before any fix likely!

Share This Page