summaryrefslogtreecommitdiff
path: root/doc/api/dgram.md
diff options
context:
space:
mode:
Diffstat (limited to 'doc/api/dgram.md')
-rw-r--r--doc/api/dgram.md6
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/api/dgram.md b/doc/api/dgram.md
index 50fd5db5a6..b9b43fcb21 100644
--- a/doc/api/dgram.md
+++ b/doc/api/dgram.md
@@ -166,6 +166,7 @@ added: v0.11.14
* `port` {integer}
* `address` {string}
* `exclusive` {boolean}
+ * `fd` {integer}
* `callback` {Function}
For UDP sockets, causes the `dgram.Socket` to listen for datagram
@@ -177,6 +178,11 @@ system will attempt to listen on all addresses. Once binding is
complete, a `'listening'` event is emitted and the optional `callback`
function is called.
+The `options` object may contain a `fd` property. When a `fd` greater
+than `0` is set, it will wrap around an existing socket with the given
+file descriptor. In this case, the properties of `port` and `address`
+will be ignored.
+
Note that specifying both a `'listening'` event listener and passing a
`callback` to the `socket.bind()` method is not harmful but not very
useful.