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

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

Re: [gawk-stable] bug: fatal error when getline from directory


From: Aharon Robbins
Subject: Re: [gawk-stable] bug: fatal error when getline from directory
Date: Mon, 05 Jan 2009 22:57:36 +0200

OK. The fix is now in the gawk-stable CVS. It should be reflected in
the repository on Savannah within an hour from this email.

The man page and reference card have been updated to indicate that
getline returns 1 on success, also.

Thanks again everyone.

Arnold

> Date: Mon, 5 Jan 2009 22:20:24 +0200
> From: Aharon Robbins <address@hidden>
> To: address@hidden, address@hidden
> Subject: Re: [gawk-stable] bug: fatal error when getline from directory
> Cc: address@hidden, address@hidden, address@hidden,
>         address@hidden
>
> Hi Everyone.
>
> Thanks for all the discussion / opinions / contributions.
>
> > Date: Mon, 5 Jan 2009 14:43:21 +0100
> > To: Eric Blake <address@hidden>
> > Cc: Aharon Robbins <address@hidden>, address@hidden,
> >         address@hidden, address@hidden
> > Subject: Re: [gawk-stable] bug: fatal error when getline from directory
> > From: Paolo <address@hidden>
> >
> > [....]
> >
> > Re-stating it, back to original bug-rep point, I'm pretty fine with getline
> > raising an error on attempt reading a dir, till/unless an extension is avail
> >  - actually, I want such behaviour instead of EOF from nawk - yet I deem
> > it wrong to issue a fatal: and abort script.
> >
> > While you've provided arguments for awk not trying to read from a dir, I
> > fail to see any single good point for a fatal abort of getline, instead of
> > usual & documented rc=-1 on error behaviour, which is the bug reported.
>
> I agree with this.  I will fix gawk-stable such that getline from
> a directory returns -1 and sets ERRNO appropriately. I think that
> BWK awk's returning 0 in this case is a bug.
>
> For the moment, gawk will continue to treat a directory on the
> command line as a fatal error.
>
> Paolo, thanks for the original bug report. Steffen, thanks for bringing
> it to my attention.
>
> Arnold




reply via email to

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