diff options
Diffstat (limited to 'xC.c')
-rw-r--r-- | xC.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -3068,6 +3068,15 @@ relay_prepare_buffer_update (struct app_context *ctx, struct buffer *buffer) struct relay_event_data_buffer_update *e = &m->data.buffer_update; e->event = RELAY_EVENT_BUFFER_UPDATE; e->buffer_name = str_from_cstr (buffer->name); +} + +static void +relay_prepare_buffer_stats (struct app_context *ctx, struct buffer *buffer) +{ + struct relay_event_message *m = relay_prepare (ctx); + struct relay_event_data_buffer_stats *e = &m->data.buffer_stats; + e->event = RELAY_EVENT_BUFFER_STATS; + e->buffer_name = str_from_cstr (buffer->name); e->new_messages = MIN (UINT32_MAX, buffer->new_messages_count - buffer->new_unimportant_count); e->new_unimportant_messages = MIN (UINT32_MAX, @@ -15223,6 +15232,8 @@ client_resync (struct client *c) { relay_prepare_buffer_update (c->ctx, buffer); relay_send (c); + relay_prepare_buffer_stats (c->ctx, buffer); + relay_send (c); LIST_FOR_EACH (struct buffer_line, line, buffer->lines) { |