udp-free-port
v1.0.0
Published
Get a free udp port, for node
Downloads
23
Readme
udp-free-port
Get a free udp port, for node
Install
npm i udp-free-port --save
Usage
'use strict'
freeUdpPort(function (err, port) {
if (err) {
throw err // or do something else
}
// user your port!
var socket = dgram.createSocket('udp4')
socket.bind(port, function (err) {
if (err) {
throw err // or do something else
}
})
})
License
MIT