Make it work with NetBSD 1.3.2.

1998-12-05  Martin Baulig  <martin@home-of-linux.org>

	* Make it work with NetBSD 1.3.2.

Well, it compiles without problems but not all features are currently
working; need to look a little bit closer at it.

Ok for now, think I'll install OpenBSD and test it there ...

Martin
This commit is contained in:
Martin Baulig
1998-12-05 18:52:09 +00:00
committed by Martin Baulig
parent d414a22ee3
commit 67a344b9d4
12 changed files with 108 additions and 14 deletions

View File

@@ -135,8 +135,13 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_map *buf,
update = 1;
}
#ifdef __FreeBSD__
if (entry.eflags & (MAP_ENTRY_IS_A_MAP|MAP_ENTRY_IS_SUB_MAP))
continue;
#else
if (entry.is_a_map || entry.is_sub_map)
continue;
#endif
maps [i].flags = _glibtop_sysdeps_map_entry;
@@ -165,6 +170,7 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_map *buf,
&object, sizeof (object)) != sizeof (object))
glibtop_error_io_r (server, "kvm_read (object)");
#ifdef __FreeBSD__
/* If the object is of type vnode, add its size */
if (object.type != OBJT_VNODE)
@@ -193,7 +199,7 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_map *buf,
maps [i-1].inode = inode.i_number;
maps [i-1].device = inode.i_dev;
#endif
} while (entry.next != first);
return maps;