1. Feb 16, 2013
    • isaacs's avatar
      fs: Change default WriteStream config, increase perf · 8476aefc
      isaacs authored
      This increases fs.WriteStream throughput dramatically by removing the
      "higher default water marks" for fs.WriteStream.
      
      Also includes a benchmark.  Current performance is significantly higher
      than v0.8 for strings at all tested levels except size=1.  Buffer
      performance is still lackluster.
      
      Further improvement in the stream.Writable base class is required, but
      this is a start.
      8476aefc
    • isaacs's avatar
      test: Bump up debugger timeouts · 9299168f
      isaacs authored
      200ms is still short enough for occasional spurious failures.
      9299168f
    • Trevor Norris's avatar
      process: allow ticker to cross communicate better · ec420006
      Trevor Norris authored
      Using external memory values allows for quick communication between js
      and cc land, so we can check if the js land callback needs to be run.
      (this is where I meant that manually tracking nextTickQueue.length would
      be helpful)
      
      Also did some minor cleanup of removing the old Tick and
      StartTickSpinner functions, and a few unneeded comments.
      
      Conflicts:
      
      	src/node.cc
      ec420006
    • Trevor Norris's avatar
      process: streamlining tick callback logic · 86c0745a
      Trevor Norris authored
      * Callbacks from spinner now calls its own function, separate from the
        tickCallback logic
      * MakeCallback will call a domain specific function if a domain is
        detected
      * _tickCallback assumes no domains, until nextTick receives a callback
        with a domain. After that _tickCallback is overridden with the domain
        specific implementation.
      * _needTickCallback runs in startup() instead of nextTick (isaacs)
      * Fix bug in _fatalException where exit would be called twice (isaacs)
      * Process.domain has a default value of null
      * Manually track nextTickQueue.length (will be useful later)
      * Update tests to reflect internal api changes
      86c0745a
    • isaacs's avatar
      Revert "Move MakeCallback to JS" · 95ac576b
      isaacs authored
      This reverts commit 0109a9f9.
      
      Also included:  Port all the changes to process._makeCallback into the
      C++ version.  Immediate nextTick, etc.
      
      This yields a slight boost in several benchmarks.  V8 is optimizing and
      deoptimizing process._makeCallback repeatedly.
      95ac576b
    • Shigeki Ohtsu's avatar
      401cef79
    • Shigeki Ohtsu's avatar
      timer: move setImmediate from timer to uv_check · cd372510
      Shigeki Ohtsu authored
      uv_check is the robust place to invoke setImmediate callbacks after
      process.nextTick and before timers(setTimeout/setInterval)
      cd372510
  2. Feb 13, 2013
  3. Feb 12, 2013
    • Fedor Indutny's avatar
      test: fix tests after ECONNRESET patch · c34326b2
      Fedor Indutny authored
      c34326b2
    • Victor Costan's avatar
      Fix crypto.hmac behavior with empty keys. · e235bce2
      Victor Costan authored
      node 0.9.6 introduced Buffer changes that cause the key argument of
      Hmac::HmacInit (used in crypto.createHmac) to be NULL when the key is
      empty. This argument is passed to OpenSSL's HMAC_Init, which does not
      like NULL keys.
      
      This change works around the issue by passing an empty string to
      HMAC_Init when the key is empty, and adds crypto.createHmac tests for
      the edge cases of empty keys and values.
      e235bce2
    • isaacs's avatar
      tls: Cycle data when underlying socket drains · 02374d0c
      isaacs authored
      02374d0c
    • isaacs's avatar
      stream: read(0) should not always trigger _read(n,cb) · 1762dd7e
      isaacs authored
      This is causing the CryptoStreams to get into an awful state when
      there is a tight loop calling connection.write(chunk) waiting for
      a false return.
      
      Because CryptoStreams use read(0) to cycle data, this was causing
      the encrypted side to pull way too much data in from the cleartext
      side, since the read(0) would make it always call _read.
      
      The unfortunate side effect, fixed in the next patch, is that
      CryptoStreams don't automatically cycle when the Socket drains.
      1762dd7e
    • isaacs's avatar
      6bd45015
    • Ben Noordhuis's avatar
      crypto: improve cipher/decipher error messages · f5f9e8da
      Ben Noordhuis authored
      Throw the OpenSSL error string instead of the rather less informative
      error message "fail".
      f5f9e8da
    • isaacs's avatar
      test: update http tests for ECONNRESET change · 862b1642
      isaacs authored
      862b1642
    • Ben Noordhuis's avatar
      net: don't suppress ECONNRESET · 14a42450
      Ben Noordhuis authored
      Let ECONNRESET network errors bubble up so clients can detect them.
      
      Commit c4454d2e suppressed and turned them into regular end-of-stream
      events to fix the then-failing simple/test-regress-GH-1531 test. See
      also issue #1571 for (scant) details.
      
      It turns out that special handling is no longer necessary. Remove the
      special casing and let the error bubble up naturally.
      
      pummel/test-https-ci-reneg-attack and pummel/test-tls-ci-reneg-attack
      are updated because they expected an EPIPE error code that is now an
      ECONNRESET. Suppression of the ECONNRESET prevented the test from
      detecting that the connection has been severed whereupon the next
      write would fail with an EPIPE.
      
      Fixes #1776.
      14a42450
    • Ben Noordhuis's avatar
      fs: fix immediate WriteStream#end() · c7b84a1d
      Ben Noordhuis authored
      Fix an exception that was raised when the WriteStream was closed
      immediately after creating it:
      
        TypeError: Cannot read property 'fd' of undefined
            at WriteStream.close (fs.js:1537:18)
            <snip>
      
      Avoid the TypeError and make sure the file descriptor is closed.
      
      Fixes #4745.
      c7b84a1d
    • Ben Noordhuis's avatar
      typed arrays: make call-as-function work for ctors · ed3d553d
      Ben Noordhuis authored
      Turn call-as-function calls into constructor calls. Makes the following
      snippet work:
      
        var buf = ArrayBuffer(32);  // no 'new' but does the right thing
      ed3d553d
    • Ben Noordhuis's avatar
      node: don't malloc in FromConstructorTemplate · aff8d9e7
      Ben Noordhuis authored
      * allocate space for argv on the stack
      * move the declaration to node_internals.h
      aff8d9e7
  4. Feb 11, 2013
    • Ben Noordhuis's avatar
      test: fix common.mustCall · d5a5ae3c
      Ben Noordhuis authored
      Don't run the 'has function been called?' checks if the test is exiting
      with an error because a failed check will mask the real exception.
      
      v0.8 doesn't have the _fatalException machinery in src/node.js and
      src/node.cc so it doesn't have this issue.
      d5a5ae3c
    • Ben Noordhuis's avatar
      doc: update buffer/typed array documentation · 30b0bc4f
      Ben Noordhuis authored
      Clarify that typed array constructors accept buffers as their first
      argument but that the memory is not shared and why this was changed
      in v0.9.
      30b0bc4f
    • Ben Noordhuis's avatar
      typed arrays: copy Buffer in typed array constructor · 5a9d30bb
      Ben Noordhuis authored
      Convert the Buffer to an ArrayBuffer. The typed_array.buffer property
      should be an ArrayBuffer to avoid confusion: a Buffer doesn't have a
      byteLength property and more importantly, its slice() method works
      subtly different.
      
      That means that before this commit:
      
        var buf = new Buffer(1);
        var arr = new Int8Array(buf);
        assert.equal(arr.buffer, buf);
        assert(arr.buffer instanceof Buffer);
      
      And now:
      
        var buf = new Buffer(1);
        var arr = new Int8Array(buf);
        assert.notEqual(arr.buffer, buf);
        assert(arr.buffer instanceof ArrayBuffer);
      5a9d30bb
  5. Feb 10, 2013
  6. Feb 09, 2013
  7. Feb 08, 2013
    • Scott Blomquist's avatar
      windows/msi: more installer enhancements · 8164b2fd
      Scott Blomquist authored
      Noteworthy installer improvements provided here:
      * Support in the Installer UI for not installing shortcuts.
      * Support in the Installer UI for choosing a custom install directory.
      * Command line support for not installing shortcuts (ADDDEFAULT=nodejs)
      * Command line support for custom install directory (INSTALLDIR=c:\tools\node)
      8164b2fd
    • Jim Schubert's avatar
      e418df7b
    • isaacs's avatar
      Now working on v0.9.10 · c3c8eee4
      isaacs authored
      c3c8eee4
    • isaacs's avatar
      Merge branch 'v0.9.9-release' · 55c4d9b3
      isaacs authored
      55c4d9b3
    • isaacs's avatar
      2013.02.07, Version 0.9.9 (Unstable) · 4b9f0d19
      isaacs authored
      * tls: port CryptoStream to streams2 (Fedor Indutny)
      
      * typed arrays: only share ArrayBuffer backing store (Ben Noordhuis)
      
      * stream: make Writable#end() accept a callback function (Nathan Rajlich)
      
      * buffer: optimize 'hex' handling (Ben Noordhuis)
      
      * dns, cares: don't filter NOTIMP, REFUSED, SERVFAIL (Ben Noordhuis)
      
      * readline: treat bare \r as a line ending (isaacs)
      
      * readline: make \r\n emit one 'line' event (Ben Noordhuis)
      
      * cluster: support datagram sockets (Bert Belder)
      
      * stream: Correct Transform class backpressure (isaacs)
      
      * addon: Pass module object to NODE_MODULE init function (isaacs, Rod Vagg)
      
      * buffer: slow buffer copy compatibility fix (Trevor Norris)
      
      * Add bytesWritten to tls.CryptoStream (Andy Burke)
      4b9f0d19
    • isaacs's avatar
      stream: Writable should ignore encoding for buffers · 33b2aebb
      isaacs authored
      Fix #4727
      Fix einaros/ws#159
      33b2aebb