[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ncurses and blocking?
From: |
Thomas Dickey |
Subject: |
Re: ncurses and blocking? |
Date: |
Tue, 9 Jul 2002 05:10:00 -0400 |
User-agent: |
Mutt/1.2.5i |
On Tue, Jul 09, 2002 at 03:06:43AM +0200, Simon Richter wrote:
> Hi,
>
> On Mon, 8 Jul 2002, Thomas Dickey wrote:
>
> [Problem: curses app which should not do any blocking I/O]
>
> > nodelay, etc:
>
> > curs_inopts(3X) curs_inopts(3X)
>
> Hrm, I think my description of the problem was inadequate. I was thinking
> of the output side, where the refresh() call could be blocking while
> writing to the terminal. I understand that this will only seldom cause
> problems, but I'd like my application to continue running even if the user
> pressed ^S. The "trivial" solution would be a multithreaded app, but I'd
> like to avoid that for portability reasons.
If you put the terminal into raw mode, it prevents ^S from doing anything:
raw();
--
Thomas E. Dickey <address@hidden>
http://invisible-island.net
ftp://invisible-island.net