TIP: Click on subject to list as thread! ANSI
echo: rberrypi
to: MARTIN GREGORIE
from: PANCHO
date: 2021-01-18 14:02:00
subject: Re: Battery Powered Proje

On 18/01/2021 13:41, Martin Gregorie wrote:
> On Mon, 18 Jan 2021 13:20:59 +0000, Pancho wrote:
>
>> I'm not sure what awk interactive/buffering means. Without the "-W
>> interactive" flag awk doesn't just buffer output, the system() call is
>> delayed too. It's more like it is buffering input.
>>
> Since you're using a pipe to pass messages from the log reader to the awk
> program, awk makes a read request which will wait for input until either
> a line of text is written to the pipe, in which case it gets read by awk
> (awk reads lines, so the message MUST be terminated by a newline) OR the
> pipe is closed, in which case awk gets an EOF and stops. If the awk
> script contains a END action, this is executed before is quits.
>
> The only apparent buffering you should see is due to awk waiting for the
> newline that terminates the line being read.
>
> About -W : according to the manpage for the awk version I'm using, 5.0.1,
> -W has nothing to do with waiting for anything. All it does is to change
> the option marker from - to --
>
> I'm using Raspbian Buster, default awk is mawk 1.3.3.

Perhaps that explains our different experience. mawk buffering doesn't
appear to be line buffering by default, i.e it buffers blocks somewhere
between 2 to 3kB (whatever the correct name for that is).

What OS are you using?

--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)

SOURCE: echomail via QWK@docsplace.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.