Added new features to get network load:

typedef struct _glibtop_netload	glibtop_netload;

struct _glibtop_netload
{
	u_int64_t	flags,
		mtu,			/* GLIBTOP_NETLOAD_MTU		*/
		address,		/* GLIBTOP_NETLOAD_ADDRESS	*/
		packets_in,		/* GLIBTOP_NETLOAD_PACKETS_IN	*/
		packets_out,		/* GLIBTOP_NETLOAD_PACKETS_OUT	*/
		bytes_in,		/* GLIBTOP_NETLOAD_BYTES_IN	*/
		bytes_out,		/* GLIBTOP_NETLOAD_BYTES_OUT	*/
		errors_in,		/* GLIBTOP_NETLOAD_ERRORS_IN	*/
		errors_out,		/* GLIBTOP_NETLOAD_ERRORS_OUT	*/
		collisions;		/* GLIBTOP_NETLOAD_COLLISIONS	*/
};

Returns network load of the given interface, it is specified as string
like `isppp' or `ippp0':

extern void glibtop_get_netload_l __P((glibtop *, glibtop_netload *, const char *));
This commit is contained in:
Martin Baulig
1998-10-26 10:39:14 +00:00
parent bdc4e08454
commit 1289b92d06
37 changed files with 550 additions and 15 deletions

View File

@@ -45,6 +45,7 @@
#include <glibtop/mountlist.h>
#include <glibtop/fsusage.h>
#include <glibtop/netload.h>
#include <glibtop/ppp.h>
__BEGIN_DECLS
@@ -73,6 +74,7 @@ union _glibtop_union
glibtop_proc_map proc_map;
glibtop_mountlist mountlist;
glibtop_fsusage fsusage;
glibtop_netload netload;
glibtop_ppp ppp;
};