Skip to content

Commit 9d3a1d4

Browse files
committed
Elaborate the highlighting of outdated/deleted executables and libraries
1 parent 60cfa2e commit 9d3a1d4

2 files changed

Lines changed: 18 additions & 6 deletions

File tree

DisplayOptionsPanel.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ DisplayOptionsPanel* DisplayOptionsPanel_new(Settings* settings, ScreenManager*
107107
Panel_add(super, (Object*) CheckItem_newByRef("Show custom thread names", &(settings->showThreadNames)));
108108
Panel_add(super, (Object*) CheckItem_newByRef("Show program path", &(settings->showProgramPath)));
109109
Panel_add(super, (Object*) CheckItem_newByRef("Highlight program \"basename\"", &(settings->highlightBaseName)));
110-
Panel_add(super, (Object*) CheckItem_newByRef("Highlight out-dated/removed programs", &(settings->highlightDeletedExe)));
110+
Panel_add(super, (Object*) CheckItem_newByRef("Highlight out-dated/removed programs (red) / libraries (yellow)", &(settings->highlightDeletedExe)));
111111
Panel_add(super, (Object*) CheckItem_newByRef("Merge exe, comm and cmdline in Command", &(settings->showMergedCommand)));
112112
Panel_add(super, (Object*) CheckItem_newByRef("- Try to find comm in cmdline (when Command is merged)", &(settings->findCommInCmdline)));
113113
Panel_add(super, (Object*) CheckItem_newByRef("- Try to strip exe from cmdline (when Command is merged)", &(settings->stripExeFromCmdline)));

htop.1.in

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -285,19 +285,31 @@ is active, the executable path (/proc/[pid]/exe) and the command name
285285
(/proc/[pid]/comm) are also shown merged with the command line, if available.
286286

287287
The program basename is highlighted if set in the configuration. Additional
288-
highlighting can be configured for stale executables (cf. Exe column below).
288+
highlighting can be configured for stale executables (cf. EXE column below).
289289
.TP
290-
.B Comm
290+
.B COMM
291291
The command name of the process obtained from /proc/[pid]/comm, if readable.
292292
.TP
293-
.B Exe
293+
.B EXE
294294
The abbreviated basename of the executable of the process, obtained from
295295
/proc/[pid]/exe, if readable. htop is able to read this file on linux for ALL
296296
the processes only if it has the capability CAP_SYS_PTRACE or root privileges.
297297

298298
The basename is marked in red if the executable used to run the process has
299-
been replaced or deleted on disk since the process started. This additional
300-
markup can be configured.
299+
been replaced or deleted on disk since the process started. The information is
300+
obtained by processing the contents of /proc/[pid]/exe.
301+
302+
Furthermore the basename is marked in yellow if any library is reported as having
303+
been replaced or deleted on disk since it was last loaded. The information is
304+
obtained by processing the contents of /proc/[pid]/maps.
305+
306+
When deciding the color the replacement of the main executable always takes
307+
precedence over replacement of any other library. If only the memory map indicates
308+
a replacement of the main executable, this will show as if any other library had
309+
been replaced or deleted.
310+
311+
This additional color markup can be configured in the "Display Options" section of
312+
the setup screen.
301313
.TP
302314
.B PID
303315
The process ID.

0 commit comments

Comments
 (0)