summaryrefslogtreecommitdiff
path: root/bus/stats.c
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2011-02-08 15:48:12 +0000
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2011-06-24 16:01:56 +0100
commit30f116fd2d20cbeb13ed20f1f780d8aa92e67983 (patch)
treeeff2f508080fb2c8f35f93883fe9bb823a06b03d /bus/stats.c
parentcf08dce40281fa128f717b33c64c165cbcd753f6 (diff)
Include size of link cache in per-connection statistics
Reviewed-by: Cosimo Alfarano <cosimo.alfarano@collabora.co.uk> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=34040
Diffstat (limited to 'bus/stats.c')
-rw-r--r--bus/stats.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/bus/stats.c b/bus/stats.c
index 28fd49ba3..4e7288596 100644
--- a/bus/stats.c
+++ b/bus/stats.c
@@ -263,6 +263,7 @@ bus_stats_handle_get_connection_stats (DBusConnection *caller_connection,
static dbus_uint32_t stats_serial = 0;
dbus_uint32_t in_messages, in_bytes, in_fds, in_peak_bytes, in_peak_fds;
dbus_uint32_t out_messages, out_bytes, out_fds, out_peak_bytes, out_peak_fds;
+ dbus_uint32_t link_cache_bytes;
BusRegistry *registry;
BusService *service;
DBusConnection *stats_connection;
@@ -315,7 +316,8 @@ bus_stats_handle_get_connection_stats (DBusConnection *caller_connection,
&in_messages, &in_bytes, &in_fds,
&in_peak_bytes, &in_peak_fds,
&out_messages, &out_bytes, &out_fds,
- &out_peak_bytes, &out_peak_fds);
+ &out_peak_bytes, &out_peak_fds,
+ &link_cache_bytes);
if (!asv_add_uint32 (&iter, &arr_iter, "IncomingMessages", in_messages) ||
!asv_add_uint32 (&iter, &arr_iter, "IncomingBytes", in_bytes) ||
@@ -326,7 +328,8 @@ bus_stats_handle_get_connection_stats (DBusConnection *caller_connection,
!asv_add_uint32 (&iter, &arr_iter, "OutgoingBytes", out_bytes) ||
!asv_add_uint32 (&iter, &arr_iter, "OutgoingFDs", out_fds) ||
!asv_add_uint32 (&iter, &arr_iter, "PeakOutgoingBytes", out_peak_bytes) ||
- !asv_add_uint32 (&iter, &arr_iter, "PeakOutgoingFDs", out_peak_fds))
+ !asv_add_uint32 (&iter, &arr_iter, "PeakOutgoingFDs", out_peak_fds) ||
+ !asv_add_uint32 (&iter, &arr_iter, "LinkCacheBytes", link_cache_bytes))
goto oom;
/* end */