diff options
| author | Masatake YAMATO <yamato@redhat.com> | 2025-10-04 05:21:35 +0900 |
|---|---|---|
| committer | Masatake YAMATO <yamato@redhat.com> | 2025-10-04 05:32:51 +0900 |
| commit | 48f7dccbb095b9892c1807c7f901c77e07417a67 (patch) | |
| tree | 115db7eb4ce0c25b62cfeba739d3b87b0e563079 /misc-utils/kill.c | |
| parent | eb0e08a76e3ebd4571b957e727847060304c32bb (diff) | |
| download | util-linux-48f7dccbb095b9892c1807c7f901c77e07417a67.tar.gz | |
kill: (refactor) rename parameter to better reflect its purpose
Signed-off-by: Masatake YAMATO <yamato@redhat.com>
Diffstat (limited to 'misc-utils/kill.c')
| -rw-r--r-- | misc-utils/kill.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/misc-utils/kill.c b/misc-utils/kill.c index 5b73d24e7a..7ffcee6327 100644 --- a/misc-utils/kill.c +++ b/misc-utils/kill.c @@ -203,13 +203,13 @@ static void pretty_print_signal(FILE *fp, size_t term_width, size_t *lpos, fprintf(fp, "%2d %-8s", signum, name); } -static void print_all_signals(FILE *fp, int pretty) +static void print_all_signals(FILE *fp, int with_signum) { size_t n, lth, lpos = 0, width; const char *signame = NULL; int signum = 0; - if (!pretty) { + if (!with_signum) { for (n = 0; get_signame_by_idx(n, &signame, NULL) == 0; n++) { lth = 1 + strlen(signame); if (KILL_OUTPUT_WIDTH < lpos + lth) { @@ -227,7 +227,7 @@ static void print_all_signals(FILE *fp, int pretty) return; } - /* pretty print */ + /* with signal numbers */ width = get_terminal_width(KILL_OUTPUT_WIDTH + 1) - 1; for (n = 0; get_signame_by_idx(n, &signame, &signum) == 0; n++) pretty_print_signal(fp, width, &lpos, signum, signame); |
