summary refs log tree commit diff stats
path: root/lib/pure/net.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2016-03-29 15:30:44 +0200
committerAraq <rumpf_a@web.de>2016-03-29 15:31:10 +0200
commitdb2b2156581ffaaa63e7ff9c0a07ced540006956 (patch)
tree341535aa355ef422ee886f7b14fda6fbfeae0523 /lib/pure/net.nim
parent8bf14b12a963980e71ad46e16a8a2e35c9465b8c (diff)
parentb4f1eef3a3b0ff56d0a68c15c43ffecb7778e939 (diff)
downloadNim-db2b2156581ffaaa63e7ff9c0a07ced540006956.tar.gz
resolved merge conflicts
Diffstat (limited to 'lib/pure/net.nim')
-rw-r--r--lib/pure/net.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pure/net.nim b/lib/pure/net.nim
index b9764edd3..330682ca9 100644
--- a/lib/pure/net.nim
+++ b/lib/pure/net.nim
@@ -368,7 +368,7 @@ proc bindAddr*(socket: Socket, port = Port(0), address = "") {.
       name.sin_family = toInt(AF_INET).int16
     else:
       name.sin_family = toInt(AF_INET)
-    name.sin_port = htons(int16(port))
+    name.sin_port = htons(port.uint16)
     name.sin_addr.s_addr = htonl(INADDR_ANY)
     if bindAddr(socket.fd, cast[ptr SockAddr](addr(name)),
                   sizeof(name).SockLen) < 0'i32: