From 75be4598f5eb92462b47988d577e95bbea349c23 Mon Sep 17 00:00:00 2001 From: Sergey Avseyev Date: Thu, 9 Nov 2017 20:27:21 +0300 Subject: [PATCH] Fix endianness in the test --- tests/async/tnewasyncudp.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/async/tnewasyncudp.nim b/tests/async/tnewasyncudp.nim index b56cdc71bea6f..e61f630e4c012 100644 --- a/tests/async/tnewasyncudp.nim +++ b/tests/async/tnewasyncudp.nim @@ -86,7 +86,7 @@ proc readMessages(server: AsyncFD) {.async.} = size = 0 var grammString = $cstring(addr buffer) if grammString.startswith("Message ") and - saddr.sin_addr.s_addr == 0x100007F: + saddr.sin_addr.s_addr == nativesockets.ntohl(INADDR_LOOPBACK.uint32): await sendTo(server, addr grammString[0], len(grammString), cast[ptr SockAddr](addr saddr), slen) inc(msgCount)