iomenu

interactive text selection menu
Log | Files | Refs | README | LICENSE

commit bfaf3a787f09d5bb9c7157233fe81bfe14f9b44b
parent 2b8b6e2287a5ea4663695d0d64aec90a1d2520da
Author: Josuah Demangeon <josuah.demangeon@gandi.net>
Date:   Mon,  4 Sep 2017 11:19:39 +0200

iomenu.1: updated -l option

Diffstat:
Miomenu.1 | 7++-----
Miomenu.c | 6+++---
2 files changed, 5 insertions(+), 8 deletions(-)

diff --git a/iomenu.1 b/iomenu.1 @@ -35,11 +35,8 @@ The selected line is printed to standard output. .It Fl l Ar lines If .Ar lines -is 0 or if -.Fl l -is not set, -the items are displayed in an horizontal list. -Otherwise, in a vertical list of at most +is 0, the items are displayed in an horizontal list; +otherwise, in a vertical list of at most .Ar lines lines. . diff --git a/iomenu.c b/iomenu.c @@ -536,9 +536,9 @@ main(int argc, char *argv[]) read_lines(); filter(); - if (!freopen("/dev/tty", "r", stdin) || - !freopen("/dev/tty", "w", stderr)) - die("freopen"); + if (!freopen("/dev/tty", "r", stdin)) die("freopen /dev/tty"); + if (!freopen("/dev/tty", "w", stderr)) die("freopen /dev/tty"); + ttyfd = open("/dev/tty", O_RDWR); set_terminal();