Closed GoogleCodeExporter closed 11 months ago
It seems to work for me:
# This file exist on my PC: /sys/class/net/eth0/carrier
$ mawk 'BEGIN { error_code = getline var < "/sys/class/net/eth0/carrier"; print
error_code; print var; print "continue..." }'
1
1
continue...
# This file does not exist on my PC: /sys/class/net/eth1/carrier
$ mawk 'BEGIN { error_code = getline var < "/sys/class/net/eth1/carrier"; print
error_code; print var; print "continue..." }'
-1
continue...
The mawk verison in Ubuntu/Debian is quite old and a lot of bugfixes for open
bugs are added in mawk from the following webpage:
http://invisible-island.net/mawk/mawk.html
Original comment by hulselma...@gmail.com
on 23 Jul 2015 at 3:53
OK. Thanks for looking into it!
Original comment by chad.gr...@appdynamics.com
on 23 Jul 2015 at 5:12
Original issue reported on code.google.com by
chad.gr...@appdynamics.com
on 8 May 2015 at 12:27