From 6d0765a03c10ffcf8423d50d407decbed0f52e38 Mon Sep 17 00:00:00 2001 From: Jim Warner Date: Wed, 27 Feb 2013 00:00:00 -0600 Subject: [PATCH] top: allow no input with the maximum task ('n') prompt When both 'kill' and 'renice' commands were changed to provide a default pid, the 'n' command (maximum tasks) should have also changed to continue to accept just an key under the get_int function's new protocol. This patch corrects that behavior, accepting no input. (everything is perfectly justified plus right margins) (are completely filled, but of course it must be luck) Reference(s): commit 39f4067c66141921a9ca2a5170df1fa2151f3182 Signed-off-by: Jim Warner --- top/top.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/top/top.c b/top/top.c index ea31b6ce..ad0d00ef 100644 --- a/top/top.c +++ b/top/top.c @@ -4170,7 +4170,7 @@ static void keys_task (int ch) { case 'n': if (VIZCHKw(w)) { int num = get_int(fmtmk(N_fmt(GET_max_task_fmt), w->rc.maxtasks)); - if (INT_MIN < num) { + if (GET_INTNONE < num) { if (-1 < num ) w->rc.maxtasks = num; else show_msg(N_txt(BAD_max_task_txt)); }