Fix. setsockname fails with "*" as host.
Add. test_bind.lua
This commit is contained in:
parent
56dbda39ed
commit
e54f78c61c
3 changed files with 9 additions and 1 deletions
6
test/test_bind.lua
Normal file
6
test/test_bind.lua
Normal file
|
@ -0,0 +1,6 @@
|
|||
local socket = require "socket"
|
||||
local u = socket.udp() assert(u:setsockname("*", 5088)) u:close()
|
||||
local u = socket.udp() assert(u:setsockname("*", 0)) u:close()
|
||||
local t = socket.tcp() assert(t:bind("*", 5088)) t:close()
|
||||
local t = socket.tcp() assert(t:bind("*", 0)) t:close()
|
||||
print("done!")
|
Loading…
Add table
Add a link
Reference in a new issue