Skip to content

Commit

Permalink
fixed issue TooTallNate#2 addMembership() should come after bind()
Browse files Browse the repository at this point in the history
  • Loading branch information
SamDecrock committed May 31, 2012
1 parent e6ba669 commit 363b924
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/upnp.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,11 @@ if (process.env.NODE_DEBUG && /upnp/.test(process.env.NODE_DEBUG)) {
function ControlPoint() {
events.EventEmitter.call(this);
this.server = dgram.createSocket('udp4');
this.server.addMembership(BROADCAST_ADDR);
var self = this;
this.server.on('message', function(msg, rinfo) {self.onRequestMessage(msg, rinfo);});
this._initParsers();
this.server.bind(SSDP_PORT);
this.server.addMembership(BROADCAST_ADDR); //fixed issue #2
}
util.inherits(ControlPoint, events.EventEmitter);
exports.ControlPoint = ControlPoint;
Expand Down

0 comments on commit 363b924

Please sign in to comment.