Bug#649147: /usr/bin/mawk: mawk function substr do not work correctly

2011-11-18 Thread Jonathan Nieder
severity 649147 wishlist tags 649147 + fixed-upstream quit Hi Frank, Frank Sell wrote: > date +"%y-%m-%d %H:%M:%S" | mawk '{ printf ("%s %s\n", $2, substr($2, 0, 5)) > }' > 08:57:41 08:5 POSIX sayeth: substr(s, m[, n ]) Return the at most n-character substring of s that begin

Bug#649147: /usr/bin/mawk: mawk function substr do not work correctly

2011-11-18 Thread Frank Sell
Package: mawk Version: 1.3.3-15 Severity: normal File: /usr/bin/mawk Indexing of substr in mawk is not correct date +"%y-%m-%d %H:%M:%S" | mawk '{ printf ("%s %s\n", $2, substr($2, 0, 5)) }' 08:57:41 08:5 gawk is korrekt date +"%y-%m-%d %H:%M:%S" | gawk '{ printf ("%s %s\n", $2, substr($2, 0,