r2969: inet_ntoa() takes an address in network byte order, so now that we
authorAndrew Tridgell <tridge@samba.org>
Thu, 14 Oct 2004 09:21:12 +0000 (09:21 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 17:59:53 +0000 (12:59 -0500)
parse the RHS as IDL, we need to use htonl() to convert back to
network byte order before we can display the IP

source/torture/rpc/epmapper.c

index 1aff06007faf7f3afdc8ca53b8e2683735752589..c2450c6fbf78ecf73d646d804293c5e84dc5af98 100644 (file)
@@ -64,7 +64,7 @@ static void display_tower(TALLOC_CTX *mem_ctx, struct epm_towers *twr)
                        printf(" IP:");
                        {
                                struct in_addr in;
-                               in.s_addr = rhs->ip.address;
+                               in.s_addr = htonl(rhs->ip.address);
                                printf("%s", inet_ntoa(in));
                        }
                        break;