diff options
| author | Miguel <m.i@gmx.at> | 2018-10-13 00:57:28 +0200 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2018-10-13 00:57:28 +0200 |
| commit | 279f3336a8f6b31ca38bdd272c73aebd68fa88fe (patch) | |
| tree | b4bb4a21a4acf38eb810768ac6c1b099e2f18a58 /fs/fd.c | |
| parent | b461c3558b2fe765a4bac512638b0acf5185b4bb (diff) | |
ncurses arrow keys working etc
Diffstat (limited to 'fs/fd.c')
| -rw-r--r-- | fs/fd.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -246,6 +246,8 @@ int fds_from_pipe(fd pipefds[2]) mem+=4; *mem=1; + read.can_write=0; + read.read=pipe_get; wrt.read=0; @@ -312,6 +314,11 @@ fd fd_from_sysfs(void(*g)(ringbuffer *r,void (*f)(ringbuffer *r,char *fmt, ...)) return f; } +bool fifo_can_write(fifo *f) +{ + return !(f->full(f->data)); +} + fd fd_from_fifo(fifo* fif) { fd f; @@ -323,5 +330,6 @@ fd fd_from_fifo(fifo* fif) f.has=fifo_has; f.dupl=default_dupl; f.close=default_close; + f.can_write=fifo_can_write; return f; } |
