dgram: fix no address bind()
authorBen Noordhuis <info@bnoordhuis.nl>
Wed, 17 Apr 2013 22:44:53 +0000 (00:44 +0200)
committerBen Noordhuis <info@bnoordhuis.nl>
Wed, 17 Apr 2013 22:54:57 +0000 (00:54 +0200)
commit92023b4b37ad9bd1609b2dd2a13680dafc429f75
tree815b1fd1368609941b3576f7e3de207baaa9c1f4
parent2e70ddad9d8ef8aa37bcb18ef912cf0ff5921656
dgram: fix no address bind()

I broke dgram.Socket#bind(port, cb) almost a year ago in 332fea5a but
it wasn't until today that someone complained and none of the tests
caught it because they all either specify the address or omit the
callback.

Anyway, now it works again and does what you expect: it binds the
socket to the "any" address ("0.0.0.0" for IPv4 and "::" for IPv6.)
lib/dgram.js
test/simple/test-dgram-bind-default-address.js [new file with mode: 0644]