function receive(data) {
        stats.count += 1;
        stats.bytes += data.length;
        if (stats.count >= options.packetCount) {
            console.log('RECEIVE DONE!', info());
            // closing the channels so the process can exit
            peer1.destroy();
            peer2.destroy();
            callback();
        }
    }
/**
     * callback for the receiver to update stats and finish the test
     */
callback for the receiver to update stats and finish the test
callback for the receiver to update stats and finish the test
function receive(data) {
        stats.count += 1;
        stats.bytes += data.length;
        if (stats.count >= options.packetCount) {
            console.log('RECEIVE DONE!', info());
            peer1.destroy();
            peer2.destroy();
            callback();
        }
    }
function receive ( data ) { stats . count += 1 ; stats . bytes += data . length ; if ( stats . count >= options . packetCount ) { console . log ( 'RECEIVE DONE!' , info ( ) ) ; peer1 . destroy ( ) ; peer2 . destroy ( ) ; callback ( ) ; } }
callback for the receiver to update stats and finish the test
callback for the receiver to update stats and finish the test
// closing the channels so the process can exit