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

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

Re: [gawk] Test return value of awk statement


From: Dan Henry
Subject: Re: [gawk] Test return value of awk statement
Date: Sat, 24 Jan 2009 18:02:57 -0700

On Sat, 24 Jan 2009 19:48:06 -0500, Chris Jones <cjns1989@gmail.com>
wrote:

>I'm trying to figure out how I can test the return value of a printf
>statement in an awk script.
>
>printf "format", variable
>if (condition==bad) {exit 1}               # if printf failed, exit
>
>I have been unable to find what the "condition" in the pseudo-awk above
>might be.

Why would it fail?  stdout closed?  Anyway, I can't answer
definitively, but am interested and thus I suggest you ask on
comp.lang.awk also.

-- 
Dan Henry


reply via email to

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