iomenu

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

commit db81899f43585604025d14656fd05eba47be9060
parent e5026f5e15dba1cd072196edf8a1ead240ab4b2c
Author: Josuah Demangeon <mail@josuah.net>
Date:   Fri,  8 Dec 2017 11:31:10 +0100

style

Diffstat:
Miomenu.c | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/iomenu.c b/iomenu.c @@ -98,13 +98,13 @@ read_stdin(void) size = BUFSIZ; off = 0; - if (!(buf = malloc(size))) + if ((buf = malloc(size)) == NULL) die("malloc"); while ((len = read(STDIN_FILENO, buf + off, size - off)) > 0) { off += len; if (off >= size >> 1) { size <<= 1; - if (!(buf = realloc(buf, size + 1))) + if ((buf = realloc(buf, size + 1)) == NULL) die("realloc"); } }