From 9299e840da5ba5ff37aae658da5f41ce22319cfa Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Mon, 19 May 2014 00:06:21 +0200 Subject: fix regression MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/mds-server/mds-server.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mds-server/mds-server.c b/src/mds-server/mds-server.c index 7da5f39..a9d4422 100644 --- a/src/mds-server/mds-server.c +++ b/src/mds-server/mds-server.c @@ -443,7 +443,7 @@ int message_received(client_t* client) if (assign_id && (client->id == 0)) { intercept |= 2; - with_mutex_if (slave_mutex, (client->id = ++next_client_id) == 0, + with_mutex_if (slave_mutex, (client->id = next_client_id++) == 0, eprint("this is impossible, ID counter has overflowed."); /* If the program ran for a millennium it would take c:a 585 assignments per nanosecond. This @@ -717,6 +717,7 @@ void queue_message_multicast(char* message, size_t length, client_t* sender) goto fail_queue; sender->multicasts = new_buf; sender->multicasts[sender->multicasts_count++] = *multicast; + free(multicast); multicast = NULL; fail_queue: ); -- cgit v1.2.3-70-g09d2