summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2009-05-02 19:17:23 +0200
committerVolker Lendecke <vl@samba.org>2009-05-02 19:17:23 +0200
commiteea114a8562f71f4aadec76a767a46d7874b8972 (patch)
tree394061af7fece58bc8e6e4e29cda5a7cae3589a0
parente2052f128f4269692aede0a082351fd0dbea8cce (diff)
downloadsamba-eea114a8562f71f4aadec76a767a46d7874b8972.tar.gz
samba-eea114a8562f71f4aadec76a767a46d7874b8972.tar.bz2
samba-eea114a8562f71f4aadec76a767a46d7874b8972.zip
Fix a warning on host "gwen"
cc: "../librpc/ndr/ndr_basic.c", line 572: warning 604: Pointers are not assignment-compatible. Apparently in_addr.s_addr is not compatible to uint32_t, maybe a 32-bit signed int.
-rw-r--r--librpc/ndr/ndr_basic.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/librpc/ndr/ndr_basic.c b/librpc/ndr/ndr_basic.c
index 97f75051b7..825f30319e 100644
--- a/librpc/ndr/ndr_basic.c
+++ b/librpc/ndr/ndr_basic.c
@@ -568,9 +568,10 @@ _PUBLIC_ enum ndr_err_code ndr_pull_time_t(struct ndr_pull *ndr, int ndr_flags,
*/
_PUBLIC_ enum ndr_err_code ndr_pull_ipv4address(struct ndr_pull *ndr, int ndr_flags, const char **address)
{
+ uint32_t s_addr;
struct in_addr in;
- NDR_CHECK(ndr_pull_uint32(ndr, ndr_flags, &in.s_addr));
- in.s_addr = htonl(in.s_addr);
+ NDR_CHECK(ndr_pull_uint32(ndr, ndr_flags, &s_addr));
+ in.s_addr = htonl(s_addr);
*address = talloc_strdup(ndr->current_mem_ctx, inet_ntoa(in));
NDR_ERR_HAVE_NO_MEMORY(*address);
return NDR_ERR_SUCCESS;