Fix getline check in ui_txt (issue from 67cc541) - sacc - sacc(omys), simple console gopher client
git clone git://bitreich.org/sacc/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/sacc/
Log
Files
Refs
Tags
LICENSE
---
commit ed833e386ffe895fe2c675b549e7353fe0d3308f
parent 4d592c0484ac6270feba15d56c2796c2612a08c5
Author: Quentin Rameau 
Date:   Thu, 27 Jul 2017 01:49:07 +0200

Fix getline check in ui_txt (issue from 67cc541)

Diffstat:
  M ui_txt.c                            |       2 +-

1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/ui_txt.c b/ui_txt.c
@@ -82,7 +82,7 @@ uiprompt(char *fmt, ...)
 
         fflush(stdout);
 
-        if (getline(&input, &n, stdin))
+        if (getline(&input, &n, stdin) > 0)
                 return input;
 
         free(input);