title: process.exit(0): output disappears?
body: <p>Emacs lisp command calling <code>node hello.js</code>:</p>
  
  <pre><code>(call-process "node" nil t nil "hello.js")
  </code></pre>
  
  <p>Two variants of <code>hello.js</code>:</p>
  
  <ul>
  <li><p><code>hello_1.js</code>:</p>
  
  <pre><code>console.log('Hello world!');
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>Hello world!
  0
  </code></pre></li>
  <li><p><code>hello_2.js</code>:</p>
  
  <pre><code>console.log('Hello world!');
  process.exit(5);
  </code></pre>
  
  <p>Output (no output from log statement!):</p>
  
  <pre><code>5
  </code></pre></li>
  </ul>
  
  <p><em>What is the reason that <code>process.exit(5)</code> causes output to be suppressed?</em></p>
  
  <p>Notes:</p>
  
  <ul>
  <li><p>I experienced the problem in <em>GNU Emacs 24.3.1 (i386-mingw-nt5.1.2600) of
  2013-03-17 on MARVIN</em> in combination with <em>Node.js v0.10.18</em>, running on
  <em>Windows XP/SP3/32</em>.</p></li>
  <li><p>I tried <a href="http://www.emacswiki.org/emacs/CategoryEshell" rel="nofollow">EShell</a> to execute the node command line: no output</p></li>
  <li><p><code>process.exit()</code> calls low level <code>process.reallyExit()</code>, which causes the problem:
  no output</p>
  
  <p><code>process.reallyExit()</code> is implemented in C++:</p>
  
  <pre><code>void Exit(const FunctionCallbackInfo&lt;Value&gt;&amp; args) {
    HandleScope scope(node_isolate);
    exit(args[0]-&gt;IntegerValue());
  }
  </code></pre>
  
  <p>[...]</p>
  
  <pre><code>NODE_SET_METHOD(process, "reallyExit", Exit);
  </code></pre></li>
  </ul>