[Top][All Lists]

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

Re: [Bug-readline] How to force GNU readline to call functions bound to

From: Chet Ramey
Subject: Re: [Bug-readline] How to force GNU readline to call functions bound to 'C-d' even when line is empty
Date: Mon, 15 Jul 2013 15:23:26 -0400
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130509 Thunderbird/17.0.6

On 7/15/13 2:13 PM, Mara Kim wrote:
> Hi Chet,
> Is there any way to change this behavior? At the very least, I would want
> to return the line immediately instead of inserting an eof and allowing
> more input (current behaviour)

I'm not sure what you mean.  The current behavior is to return the line
immediately.  When readline reads the tty eof character, it sets rl_done
and breaks out of the character reading loop.  readline() ends up returning
a NULL pointer in this case.  It's up to the calling application to react
to the NULL pointer.


``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    address@hidden    http://cnswww.cns.cwru.edu/~chet/

reply via email to

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