summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
authordef <dennis@felsin9.de>2016-01-26 15:46:36 +0100
committerdef <dennis@felsin9.de>2016-01-26 16:16:55 +0100
commitc10d963e85dc78e785a8baea8b54d51bd02c43ef (patch)
tree0c7c79a3fdcecacf9782fc43ba15f276b2eebef2 /lib
parentce69f1e03781df69721cc7e3001c9461261b5bc6 (diff)
downloadNim-c10d963e85dc78e785a8baea8b54d51bd02c43ef.tar.gz
bindaddr raises ValueError exception instead of OSError
Diffstat (limited to 'lib')
-rw-r--r--lib/pure/asyncnet.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pure/asyncnet.nim b/lib/pure/asyncnet.nim
index efa87a232..a3a067497 100644
--- a/lib/pure/asyncnet.nim
+++ b/lib/pure/asyncnet.nim
@@ -456,7 +456,7 @@ proc bindAddr*(socket: AsyncSocket, port = Port(0), address = "") {.
     of AF_INET6: realaddr = "::"
     of AF_INET:  realaddr = "0.0.0.0"
     else:
-      raise newException(OSError,
+      raise newException(ValueError,
         "Unknown socket address family and no address specified to bindAddr")
 
   var aiList = getAddrInfo(realaddr, port, socket.domain)