Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
htop
Commits
3b9a4b10
Commit
3b9a4b10
authored
Feb 12, 2016
by
Hisham
Browse files
Merge branch 'master' of
https://github.com/hishamhm/htop
parents
0e3cf697
a618f477
Changes
3
Show whitespace changes
Inline
Side-by-side
freebsd/FreeBSDProcess.c
View file @
3b9a4b10
...
...
@@ -115,7 +115,7 @@ void FreeBSDProcess_writeField(Process* this, RichString* str, ProcessField fiel
char
buffer
[
256
];
buffer
[
255
]
=
'\0'
;
int
attr
=
CRT_colors
[
DEFAULT_COLOR
];
int
n
=
sizeof
(
buffer
)
-
1
;
switch
(
field
)
{
switch
(
(
int
)
field
)
{
// add FreeBSD-specific fields here
case
JID
:
snprintf
(
buffer
,
n
,
Process_pidFormat
,
fp
->
jid
);
break
;
case
JAIL
:{
...
...
@@ -143,7 +143,7 @@ long FreeBSDProcess_compare(const void* v1, const void* v2) {
p2
=
(
FreeBSDProcess
*
)
v1
;
p1
=
(
FreeBSDProcess
*
)
v2
;
}
switch
(
settings
->
sortKey
)
{
switch
(
(
int
)
settings
->
sortKey
)
{
// add FreeBSD-specific fields here
case
JID
:
return
(
p1
->
jid
-
p2
->
jid
);
...
...
freebsd/FreeBSDProcessList.c
View file @
3b9a4b10
...
...
@@ -477,8 +477,8 @@ void ProcessList_goThroughEntries(ProcessList* this) {
}
// from FreeBSD source /src/usr.bin/top/machine.c
proc
->
m_size
=
kproc
->
ki_size
/
1024
;
proc
->
m_resident
=
kproc
->
ki_rssize
*
pageSizeKb
;
proc
->
m_size
=
kproc
->
ki_size
/
1024
/
pageSizeKb
;
proc
->
m_resident
=
kproc
->
ki_rssize
;
proc
->
nlwp
=
kproc
->
ki_numthreads
;
proc
->
time
=
(
kproc
->
ki_runtime
+
5000
)
/
10000
;
...
...
freebsd/Platform.c
View file @
3b9a4b10
...
...
@@ -24,6 +24,7 @@ in the source distribution for its full text.
#include <sys/resource.h>
#include <vm/vm_param.h>
#include <time.h>
#include <math.h>
/*{
#include "Action.h"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment