mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-12 12:14:36 +03:00
Rework TTY column
* Rename internal identifier from TTY_NR to just TTY * Unify column header on platforms * Use devname(3) on BSD derivate to show the actual terminal, simplifies current FreeBSD implementation. * Use 'unsigned long int' as id type, to fit dev_t on Linux. Only on Solaris the terminal path is not yet resolved.
This commit is contained in:

committed by
cgzones

parent
36880cd61c
commit
9a8221568a
12
Process.h
12
Process.h
@ -28,7 +28,7 @@ typedef enum ProcessField_ {
|
||||
PPID = 4,
|
||||
PGRP = 5,
|
||||
SESSION = 6,
|
||||
TTY_NR = 7,
|
||||
TTY = 7,
|
||||
TPGID = 8,
|
||||
MINFLT = 10,
|
||||
MAJFLT = 12,
|
||||
@ -84,11 +84,11 @@ typedef struct Process_ {
|
||||
/* Foreground group identifier of the controlling terminal */
|
||||
int tpgid;
|
||||
|
||||
/*
|
||||
* Controlling terminal of the process.
|
||||
* The minor device number is contained in the combination of bits 31 to 20 and 7 to 0; the major device number is in bits 15 to 8.
|
||||
* */
|
||||
unsigned int tty_nr;
|
||||
/* Controlling terminal identifier of the process */
|
||||
unsigned long int tty_nr;
|
||||
|
||||
/* Controlling terminal name of the process */
|
||||
char* tty_name;
|
||||
|
||||
/* User identifier */
|
||||
uid_t st_uid;
|
||||
|
Reference in New Issue
Block a user