diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-08-24 16:01:34 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-08-24 16:01:34 +0200 |
commit | ced31fb2be1cdcc0dfc8da2b9b00105c3ad903cb (patch) | |
tree | e6544671f170bac8258e946f515dfde471125cbf /src/mds-registry/slave.c | |
parent | doc protocol stuff except message passing related stuff (diff) | |
download | mds-ced31fb2be1cdcc0dfc8da2b9b00105c3ad903cb.tar.gz mds-ced31fb2be1cdcc0dfc8da2b9b00105c3ad903cb.tar.bz2 mds-ced31fb2be1cdcc0dfc8da2b9b00105c3ad903cb.tar.xz |
message id is unsigned 32-bit
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | src/mds-registry/slave.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mds-registry/slave.c b/src/mds-registry/slave.c index 5e714d4..f98dc20 100644 --- a/src/mds-registry/slave.c +++ b/src/mds-registry/slave.c @@ -40,15 +40,15 @@ */ static int slave_notify_client(slave_t* slave) { - char buf[sizeof("To: %s\nIn response to: %s\nMessage ID: %" PRIi32 "\n\n") / sizeof(char) + 40]; + char buf[sizeof("To: %s\nIn response to: %s\nMessage ID: %" PRIu32 "\n\n") / sizeof(char) + 40]; size_t ptr = 0, sent, left; /* Construct message headers. */ - sprintf(buf, "To: %s\nIn response to: %s\nMessage ID: %" PRIi32 "\n\n", + sprintf(buf, "To: %s\nIn response to: %s\nMessage ID: %" PRIu32 "\n\n", slave->client_id, slave->message_id, message_id); /* Increase message ID. */ - message_id = message_id == INT32_MAX ? 0 : (message_id + 1); + message_id = message_id == UINT32_MAX ? 0 : (message_id + 1); /* Send message to client. */ left = strlen(buf); |