Skip to content
Snippets Groups Projects
Commit 04b491c3 authored by Lorenz Meier's avatar Lorenz Meier
Browse files

Exit top on read failure

parent 8f37e02c
No related branches found
No related tags found
No related merge requests found
......@@ -89,7 +89,11 @@ top_main(int argc, char *argv[])
if (ret > 0) {
read(0, &c, 1);
ret = read(0, &c, 1);
if (ret) {
return 1;
}
switch (c) {
case 0x03: // ctrl-c
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment