Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorBen Noordhuis <info@bnoordhuis.nl>2012-01-24 02:38:25 +0400
committerBen Noordhuis <info@bnoordhuis.nl>2012-01-24 03:11:45 +0400
commit46e86aa80348dd8e31ade16a3b19eeee6baee0de (patch)
tree0b78d4526bcf61365542b45ea65f0447d7e001ac /lib
parent986e61255736a74fad1d96cc928f049c93734e05 (diff)
dgram: bring back setMulticastLoopback()
Diffstat (limited to 'lib')
-rw-r--r--lib/dgram.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/dgram.js b/lib/dgram.js
index ee239558199..8c2ec6fcea6 100644
--- a/lib/dgram.js
+++ b/lib/dgram.js
@@ -248,7 +248,13 @@ Socket.prototype.setMulticastTTL = function(arg) {
Socket.prototype.setMulticastLoopback = function(arg) {
- throw new Error('not yet implemented');
+ arg = arg ? 1 : 0;
+
+ if (this._handle.setMulticastLoopback(arg)) {
+ throw errnoException(errno, 'setMulticastLoopback');
+ }
+
+ return arg; // 0.4 compatibility
};