bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: getline in /proc


From: Jürgen Kahrs
Subject: Re: getline in /proc
Date: Sat, 17 Sep 2005 18:25:36 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.7) Gecko/20050414

Simon Vaillancourt wrote:
> Hello,
>    I'm not sure if this is a gawk(using version 3.1.1) bug or a procfs
> issue but but when doing a getline on a file that doesn't exist in
> /proc, it loops forever, for example :
> 
> echo test | gawk 'BEGIN { while (getline <
> "/proc/anypid/unexistingfile") {print "line="$0}}'

Yes, this loops forever. And this is your bug.
Read page 62 of "The AWK Programming Language".




reply via email to

[Prev in Thread] Current Thread [Next in Thread]