From f393f8614ff2a22e4f4a0d19f63260236dfe553b Mon Sep 17 00:00:00 2001 From: Kyle Isom Date: Sat, 21 Oct 2023 19:49:36 -0700 Subject: [PATCH] Adjust phonebook help usage. - If a user requests help via the -h flag, the program shouldn't exit with an error code, and it should dump information to stdout, not stderr. --- src/bin/phonebook.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/phonebook.cc b/src/bin/phonebook.cc index ae9e976..f276b5f 100644 --- a/src/bin/phonebook.cc +++ b/src/bin/phonebook.cc @@ -159,7 +159,7 @@ main(int argc, char *argv[]) pbFile = fileName; if (help) { - usage(std::cerr, 1); + usage(std::cout, 0); } if (flags->NumArgs() == 0) {