Group :: Graphical desktop/XFce
RPM: xfce4-systemload-plugin
Main Changelog Spec Patches Sources Download Gear Bugs and FR Repocop
Patch: xfce4-systemload-plugin-1.3.2-alt1.patch
Download
Download
panel-plugin/network.cc | 8 ++++----
panel-plugin/network.h | 2 +-
panel-plugin/systemload.cc | 7 ++++---
3 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/panel-plugin/network.cc b/panel-plugin/network.cc
index 6a85dab..8ffd49b 100644
--- a/panel-plugin/network.cc
+++ b/panel-plugin/network.cc
@@ -39,7 +39,7 @@
#include <glibtop/netload.h>
static gint
-read_netload_libgtop (gulong *bytes)
+read_netload_libgtop (guint64 *bytes)
{
glibtop_netlist netlist;
char **interfaces = glibtop_get_netlist (&netlist);
@@ -60,7 +60,7 @@ read_netload_libgtop (gulong *bytes)
#else
static gint
-read_netload_libgtop (gulong *bytes)
+read_netload_libgtop (guint64 *bytes)
{
return -1;
}
@@ -70,7 +70,7 @@ read_netload_libgtop (gulong *bytes)
static const char *const PROC_NET_NETSTAT = "/proc/net/netstat";
static gint
-read_netload_proc (gulong *bytes)
+read_netload_proc (guint64 *bytes)
{
char buf[4*1024];
unsigned long long dummy, in_octets, out_octets;
@@ -112,7 +112,7 @@ read_netload_proc (gulong *bytes)
}
gint
-read_netload (gulong *net, gulong *NTotal)
+read_netload (guint64 *net, guint64 *NTotal)
{
static guint64 bytes[2];
static gint64 time[2];
diff --git a/panel-plugin/network.h b/panel-plugin/network.h
index cd574a4..e6d792f 100644
--- a/panel-plugin/network.h
+++ b/panel-plugin/network.h
@@ -33,6 +33,6 @@
/* 100 Mbit/s */
#define MAX_BANDWIDTH_BITS (100*1000*1000)
-gint read_netload (gulong *net, gulong *NTotal);
+gint read_netload (guint64 *net, guint64 *NTotal);
#endif /* _XFCE_SYSTEMLOAD_NETWORK_H_ */
diff --git a/panel-plugin/systemload.cc b/panel-plugin/systemload.cc
index 99e9edb..9aa1344 100644
--- a/panel-plugin/systemload.cc
+++ b/panel-plugin/systemload.cc
@@ -76,7 +76,7 @@ struct t_uptime_monitor {
GtkWidget *label;
GtkWidget *ebox;
- gulong value_read;
+ guint64 value_read;
};
struct t_global_monitor {
@@ -168,7 +168,8 @@ static void
update_monitors(t_global_monitor *global)
{
const SystemloadConfig *config = global->config;
- gulong MTotal = 0, MUsed = 0, NTotal = 0, STotal = 0, SUsed = 0;
+ gulong MTotal = 0, MUsed = 0, STotal = 0, SUsed = 0;
+ guint64 NTotal = 0;
for(gsize i = 0; i < G_N_ELEMENTS (global->monitor); i++)
global->monitor[i]->value_read = 0;
@@ -187,7 +188,7 @@ update_monitors(t_global_monitor *global)
}
if (systemload_config_get_enabled (config, NET_MONITOR))
{
- gulong net;
+ guint64 net;
if (read_netload (&net, &NTotal) == 0)
global->monitor[NET_MONITOR]->value_read = net;
}