ThomasDickey / original-mawk

bug-reports for mawk (originally on GoogleCode)
http://invisible-island.net/mawk/mawk.html
18 stars 2 forks source link

Incorrect parsing with -Winteractive and lots of fields #59

Closed dkogan closed 4 years ago

dkogan commented 5 years ago

Hi. I'm seeing mawk -Winteractive do the wrong thing if given a file with long lines. To reproduce, download this tiny data file: http://notes.secretsauce.net/bug.txt (the github bug tracker is refusing it for some reason). I'm observing this:

dima@scrawny:/tmp$ < bug.txt ~/projects/mawk-snapshots/mawk  '103 > NF { next } {print}'

[lots of output. This is the correct behavior]

dima@scrawny:/tmp$ < bug.txt ~/projects/mawk-snapshots/mawk -Winteractive '103 > NF { next } {print}'

[no output at all. This is wrong]

This happens with the latest code from the mawk-snapshots repo:

commit f448f2385c499fabaa9a342bb1f3e207db67daf8 (HEAD -> master, tag: t20171017, origin/master, origin/HEAD)
Author: Thomas E. Dickey <dickey@invisible-island.net>
Date:   Tue Oct 17 08:22:16 2017 +0000

    snapshot of project "mawk", label t20171017

Thanks.

ThomasDickey commented 4 years ago

fixed in 1.3.4 20200120