Fix several issues related to process information on OpenBSD and drop lsof usage.

This commit is contained in:
Robert Nagy
2014-01-23 10:39:39 +01:00
committed by Jasper Lievisse Adriaanse
parent ff07ba102f
commit df1db43032
3 changed files with 125 additions and 150 deletions

View File

@@ -78,9 +78,9 @@ glibtop_get_proc_kernel_p (glibtop *server,
return;
}
if (pinfo->p_wmesg[0])
g_strlcpy(buf->wchan, pinfo->p_wmesg[0], sizeof(buf->wchan));
if (pinfo->p_wmesg)
g_strlcpy(buf->wchan, pinfo->p_wmesg, sizeof(buf->wchan));
buf->min_flt = pinfo[0].p_uru_minflt;
buf->maj_flt = pinfo[0].p_uru_majflt;