[Bug 1333] New: awk error in gsub function

bugzilla at busybox.net bugzilla at busybox.net
Wed Mar 17 00:15:33 UTC 2010


https://bugs.busybox.net/show_bug.cgi?id=1333

           Summary: awk error in gsub function
           Product: Busybox
           Version: 1.12.x
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Other
        AssignedTo: unassigned at busybox.net
        ReportedBy: bugzilla at lordy.org.uk
                CC: busybox-cvs at busybox.net
   Estimated Hours: 0.0


gsub() ignoring word boundary

# echo 'abc' | awk '{ gsub(/\<b*/,""); print; }'
ac
# echo 'abc' | awk '{ sub(/\<b*/,""); print; }'
abc

Probably something to do with backtracking....

Compare gawk:

$ echo 'abc' | awk '{ gsub(/\<b*/,""); print; }'
abc

$ echo 'abc' | awk '{ sub(/\<b*/,""); print; }'
abc

Seen on media player

BusyBox v1.12.4 (2008-12-31 22:38:12 CET) multi-call binary
Linux hdx 2.6.15-sigma #953 PREEMPT Wed Jun 3 21:49:15 CST 2009 mips unknown

and router

BusyBox v1.12.3 (2008-12-14 02:54:58 PST) built-in shell (ash)
Linux unknown 2.4.20 #1 Sun Dec 14 03:03:26 PST 2008 mips unknown


-- 
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


More information about the busybox-cvs mailing list