Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added new files

  • Loading branch information...
commit 28ba01abfe68cdfa44e98fb9fd7bade53cff3a46 1 parent 82eb519
@coolaj86 authored
View
2  fails-on-arm/README.md
@@ -20,7 +20,7 @@ Compiling On Ubuntu
..
# or just `cmake -DCMAKE_BUILD_TYPE=Debug ..` for native builds
make
- sudo make install
+ # `sudo make install` for native builds
cd ~/
git clone git://github.com/coolaj86/node-examples-js.git
View
14 test-drain-client.js
@@ -0,0 +1,14 @@
+(function () {
+ "use strict";
+
+ var net = require('net'),
+ stream = net.createConnection('/tmp/node-drain-test.sock');
+
+ stream.on('drain', function () {
+ console.log('drain client');
+ stream.write('hello');
+ });
+ stream.on('data', function (data) {
+ console.log(data.toString());
+ });
+}());
View
14 test-drain-server.js
@@ -0,0 +1,14 @@
+(function () {
+ "use strict";
+
+ var net = require('net');
+
+ net.createServer(function (stream) {
+ stream.on('drain', function () {
+ console.log('drain server');
+ });
+ stream.on('data', function (data) {
+ stream.write("echo " + data.toString() + new Buffer(9096).toString());
+ });
+ }).listen('/tmp/node-drain-test.sock');
+}());
Please sign in to comment.
Something went wrong with that request. Please try again.