Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
change event error to smppError since error seems to cause problems w…
…ith node
  • Loading branch information
bjyoungblood committed Jan 5, 2012
1 parent 874c001 commit 152303d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/server-connection.js
Expand Up @@ -89,15 +89,15 @@ var serverConnection = function(socket, server, closeConnectionServerCallback, c
parsedBuffer = data.fromBuffer(buffer, self.splitPacketBuffer);
} catch (err) {
self.generic_nack();
self.emit('error', self, err);
self.emit('smppError', self, err);
return;
}

// something went wrong very with parsing the data the client sent --
// best to just scrap it and tell them to reconnect
if (typeof parsedBuffer !== "object") {
self.generic_nack();
self.emit('error', self, "bad data from client or something");
self.emit('smppError', self, "bad data from client or something");
return;
}

Expand Down Expand Up @@ -423,7 +423,7 @@ var serverConnection = function(socket, server, closeConnectionServerCallback, c
}

self.destroy();
self.emit('error', self, e);
self.emit('smppError', self, e);
};
};

Expand Down

0 comments on commit 152303d

Please sign in to comment.