>From eb8a81adfa05cfa8b62291bac0052c4e15124a8e Mon Sep 17 00:00:00 2001 From: Jakub Hrozek Date: Fri, 25 May 2012 11:51:11 +0200 Subject: [PATCH] Use uint32_t to copy the service port --- src/responder/nss/nsssrv_services.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/responder/nss/nsssrv_services.c b/src/responder/nss/nsssrv_services.c index 2e539f13576d18c97d8c3bff2ced2fd5ed01290f..3a6e1b07866a539b36284446e60b2d507d312275 100644 --- a/src/responder/nss/nsssrv_services.c +++ b/src/responder/nss/nsssrv_services.c @@ -1041,13 +1041,13 @@ errno_t parse_getservbyport(TALLOC_CTX *mem_ctx, errno_t ret; size_t i, j; size_t port_and_padding_len; - uint16_t c, port; + uint32_t c, port; char *protocol; TALLOC_CTX *tmp_ctx = talloc_new(NULL); if (!tmp_ctx) return ENOMEM; /* Copy in the port */ - SAFEALIGN_COPY_UINT16(&c, body, NULL); + SAFEALIGN_COPY_UINT32(&c, body, NULL); port = ntohs(c); port_and_padding_len = 2 * sizeof(uint16_t) + sizeof(uint32_t); -- 1.7.10.1