Skip to content
This repository has been archived by the owner on Feb 11, 2020. It is now read-only.

Commit

Permalink
Merge dc92295 into ae59321
Browse files Browse the repository at this point in the history
  • Loading branch information
martin-doyle committed Mar 9, 2018
2 parents ae59321 + dc92295 commit e0737e0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 13 deletions.
15 changes: 2 additions & 13 deletions .travis.yml
@@ -1,33 +1,22 @@
language: node_js
sudo: false
node_js:
- 0.12
- 4
- 6
- 8
services:
- redis-server
- mongodb
script:
- npm run coverage
after_success:
- npm run publish-coverage
env:
global:
- CC=gcc-4.8
- CXX=g++-4.8
- MONGODB_VERSION="3.4.9"
- CXX=g++-4.8
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.8
- g++-4.8
- libzmq3-dev
before_install:
- wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-$MONGODB_VERSION.tgz
- tar xfz mongodb-linux-x86_64-$MONGODB_VERSION.tgz
- export PATH=`pwd`/mongodb-linux-x86_64-$MONGODB_VERSION/bin:$PATH
- mkdir -p data/db
- mongod --dbpath=data/db > /dev/null &
- sleep 5
6 changes: 6 additions & 0 deletions lib/server.js
Expand Up @@ -216,6 +216,12 @@ function Server(opts, callback) {
var server = interfaces.serverFactory(iface, fallback, that);
that.servers.push(server);
server.maxConnections = iface.maxConnections || 10000000;

// Catch listen errors
server.on('error', function (e) {
that.logger.error('Error starting Mosca Server');
that.emit('error', e);
});
server.listen(port, host, dn);
}, done);
},
Expand Down

0 comments on commit e0737e0

Please sign in to comment.