npm

Nihal's Password Manager (WIP)
git clone git://git.nihaljere.xyz/npm
Log | Files | Refs | LICENSE

commit 52b69d74ec9d03bb7cc7fa11596f98950ea189ee
parent fd08e3cd52319a13dd5947287064805f2c90942d
Author: Nihal Jere <nihal@nihaljere.xyz>
Date:   Tue, 28 Sep 2021 11:56:09 -0500

npmc: return success only if answer is not empty

Diffstat:
Mnpmc.c | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/npmc.c b/npmc.c @@ -89,10 +89,11 @@ main(int argc, char *argv[]) read_answer(sock); - printf("%s", answer); + if (*answer) + printf("%s", answer); closesock: close(sock); end: - return 0; + return !(*answer); }