- Oct 29, 2015
-
-
Rod Vagg authored
Notable changes: * buffer: (Breaking) Removed both 'raw' and 'raws' encoding types from Buffer, these have been deprecated for a long time (Sakthipriyan Vairamani) #2859. * console: (Breaking) Values reported by console.time() now have 3 decimals of accuracy added (Michaël Zasso) #3166. * fs: - fs.readFile*(), fs.writeFile*(), and fs.appendFile*() now also accept a file descriptor as their first argument (Johannes Wüller) #3163. - (Breaking) In fs.readFile(), if an encoding is specified and the internal toString() fails the error is no longer thrown but is passed to the callback (Evan Lucas) #3485. - (Breaking) In fs.read() (using the fs.read(fd, length, position, encoding, callback) form), if the internal toString() fails the error is no longer thrown but is passed to the callback (Evan Lucas) #3503. * http: - Fixed a bug where pipelined http requests would stall (Fedor Indutny) #3342. - (Breaking) When parsing HTTP, don't add duplicates of the following headers: Retry-After, ETag, Last-Modified, Server, Age, Expires. This is in addition to the following headers which already block duplicates: Content-Type, Content-Length, User-Agent, Referer, Host, Authorization, Proxy-Authorization, If-Modified-Since, If-Unmodified-Since, From, Location, Max-Forwards (James M Snell) #3090. - (Breaking) The callback argument to OutgoingMessage#setTimeout() must be a function or a TypeError is thrown (James M Snell) #3090. - (Breaking) HTTP methods and header names must now conform to the RFC 2616 "token" rule, a list of allowed characters that excludes control characters and a number of separator characters. Specifically, methods and header names must now match /^[a-zA-Z0-9_!#$%&'*+.^`|~-]+$/ or a TypeError will be thrown (James M Snell) #2526. * node: - (Breaking) Deprecated the _linklist module (Rich Trott) #3078. - (Breaking) Removed require.paths and require.registerExtension(), both had been previously set to throw Error when accessed (Sakthipriyan Vairamani) #2922. * npm: Upgraded to version 3.3.6 from 2.14.7, see https://github.com/npm/npm/releases/tag/v3.3.6 for more details. This is a major version bump for npm and it has seen a significant amount of change. Please see the original npm v3.0.0 release notes for a list of major changes (Rebecca Turner) #3310. * src: (Breaking) Bumped NODE_MODULE_VERSION to 47 from 46, this is necessary due to the V8 upgrade. Native add-ons will need to be recompiled (Rod Vagg) #3400. * timers: Attempt to reuse the timer handle for setTimeout().unref(). This fixes a long-standing known issue where unrefed timers would perviously hold beforeExit open (Fedor Indutny) #3407. * tls: - Added ALPN Support (Shigeki Ohtsu) #2564. - TLS options can now be passed in an object to createSecurePair() (Коренберг Марк) #2441. - (Breaking) The default minimum DH key size for tls.connect() is now 1024 bits and a warning is shown when DH key size is less than 2048 bits. This a security consideration to prevent "logjam" attacks. A new minDHSize TLS option can be used to override the default. (Shigeki Ohtsu) #1831. * util: - (Breaking) util.p() was deprecated for years, and has now been removed (Wyatt Preul) #3432. - (Breaking) util.inherits() can now work with ES6 classes. This is considered a breaking change because of potential subtle side-effects caused by a change from directly reassigning the prototype of the constructor using `ctor.prototype = Object.create(superCtor.prototype, { constructor: { ... } })` to using `Object.setPrototypeOf(ctor.prototype, superCtor.prototype)` (Michaël Zasso) #3455. * v8: (Breaking) Upgraded to 4.6.85.25 from 4.5.103.35 (Ali Ijaz Sheikh) #3351. - Implements the spread operator, see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Spread_operator for further information. - Implements new.target, see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/new.target for further information. * zlib: Decompression now throws on truncated input (e.g. unexpected end of file) (Yuval Brik) #2595. PR-URL: https://github.com/nodejs/node/pull/3466
-
Myles Borins authored
Currently util.format is being used for string templating in tls. By replacing all of the instances of util.format with backtick string we can remove the need to require util in tls all together. PR-URL: https://github.com/nodejs/node/pull/3456 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Fedor Indutny <fedor@indutny.com>
-
Rich Trott authored
The documentation indicates that child.send() returns a boolean but it has returned undefinined at since v0.12.0. It now returns a boolean per the (slightly updated) documentation. PR-URL: https://github.com/nodejs/node/pull/3516 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Junliang Yan authored
Fix the following error message in windows using VS 2013: LINK : fatal error LNK1194: cannot delay-load 'node.exe' due to import of data symbol '"__declspec(dllimport) const v8::OutputStream::`vftable'" (__imp_??_7OutputStream@v8@@6B@)'; link without /DELAYLOAD:node.exe PR-URL: https://github.com/nodejs/node/pull/3572 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Junliang Yan authored
PR-URL: https://github.com/nodejs/node/pull/3532 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Rich Trott authored
Move ENOENT related tests out of general fs.watch() test file and into its own file. This may help diagnose https://github.com/nodejs/node/issues/3541. PR-URL: https://github.com/nodejs/node/pull/3548 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Michaël Zasso <mic.besace@gmail.com> Reviewed-By:
Johan Bergström <bugs@bergstroem.nu>
-
Myles Borins authored
There is currently no information in the Collaborators guide regarding LTS. This commit adds some basic copy explaining what LTS is, what is considered for LTS, and a simple way collaborators can help. Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Steven R. Loomis <srloomis@us.ibm.com> PR-URL: https://github.com/nodejs/node/pull/3442
-
Ali Ijaz Sheikh authored
This is a reland of https://github.com/nodejs/node/pull/3165. The patch abates the truncation of script filenames in the perf-event output produced by V8. V8 commits: Original: https://github.com/v8/v8/commit/03ef3cd004c2fd31ae7e48772f106df67b8c2feb Reland: https://github.com/v8/v8/commit/010897c16adb46d3fe403eab525502a63e174b0c Original commit message: improve perf_basic_prof filename reporting The buffer used for appending filenames to the string printed to the perf_basic_prof log was unnecessarily too small. Bump it up to be at least kUtf8BufferSize. Truncation of filenames makes it really hard to work with profiles gathered on Node.js. Because of the way Node.js works, you can have node module dependencies in deeply nested directories. The last thing you want when investigating a performance problem is to have script names be truncated. This patch is a stop-gap. Ideally, I want no truncation of the filename at all and use a dynamically growing buffer. That would be a larger change, and I wanted to have a quick fix available that can be back-ported to Node.js LTS release. R=yangguo@chromium.org,yurys@chromium.org BUG= Review URL: https://codereview.chromium.org/1388543002 PR-URL: https://github.com/nodejs/node/pull/3520 Reviewed-By:
bnoordhuis - Ben Noordhuis <info@bnoordhuis.nl>
-
Stefan Budeanu authored
Tests normally use common.PORT to allow the user to select which port number to listen on. Hardcoding the port number will cause parallel instances of the test to fail. PR-URL: https://github.com/nodejs/node/pull/3557 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Fedor Indutny <fedor@indutny.com> Reviewed-By:
Johan Bergström <bugs@bergstroem.nu>
-
Sakthipriyan Vairamani authored
The `tls` module's `createServer` and `createSecureContext` accept `key` option and it can be an array of keys as well. This patch explains the format of the entries in that array. Corresponding code: https://github.com/nodejs/node/blob/v4.1.1/lib/_tls_common.js#L73-L90 PR-URL: https://github.com/nodejs/node/pull/3123 Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
Fedor Indutny <fedor.indutny@gmail.com>
-
Sakthipriyan Vairamani authored
As it is, the comments are not handled properly in REPL. So, if the comments have `'` or `"`, then they are treated as incomplete string literals and the error is thrown in REPL. This patch refactors the existing logic and groups everything in a class. Fixes: https://github.com/nodejs/node/issues/3421 PR-URL: https://github.com/nodejs/node/pull/3515 Reviewed-By:
Brian White <mscdex@mscdex.net> Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com>
-
Fedor Indutny authored
Original commit message: [heap] fix crash during the scavenge of ArrayBuffer Scavenger should not attempt to visit ArrayBuffer's storage, it is a user-supplied pointer that may have any alignment. Visiting it, may result in a crash. BUG= R=jochen Review URL: https://codereview.chromium.org/1406133003 Cr-Commit-Position: refs/heads/master@{#31611} PR-URL: https://github.com/nodejs/node/pull/3549 Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-
Sakthipriyan Vairamani authored
As per the `prefer-const` eslint rule, few instances of `let` have been identified to be better with `const`. This patch updates all those instances. Refer: https://github.com/nodejs/node/issues/3118 PR-URL: https://github.com/nodejs/node/pull/3152 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Сковорода Никита Андреевич <chalkerx@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
Michaël Zasso <mic.besace@gmail.com>
-
Sakthipriyan Vairamani authored
Description from: http://eslint.org/docs/rules/prefer-const.html If a variable is never modified, using the `const` declaration is better. `const` declaration tells readers, "this variable is never modified," reducing cognitive load and improving maintainability. Refer: https://github.com/nodejs/node/issues/3118 PR-URL: https://github.com/nodejs/node/pull/3152 Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Сковорода Никита Андреевич <chalkerx@gmail.com> Reviewed-By:
Roman Reiss <me@silverwind.io> Reviewed-By:
Michaël Zasso <mic.besace@gmail.com>
-
Rich Trott authored
It is possible to cause a resource leak in SharedHandle. This commit fixes the leak. Fixes: https://github.com/nodejs/node/issues/2510 PR-URL: https://github.com/nodejs/node/pull/3510 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Ron Korving authored
PR-URL: https://github.com/nodejs/node/pull/2947 Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-
Ben Noordhuis authored
Before this commit, sending a SIGUSR1 at program exit could trigger a hard to reproduce race condition where `v8::Debug::DebugBreak(isolate)` got called when the isolate was in the process of being torn down. A similar race condition is in theory possible when sending signals to two threads simultaneously but I haven't been able to reproduce that myself (and I tried, oh how I tried.) This commit fixes the race condition by turning `node_isolate` into a `std::atomic` and using it as an ad hoc synchronization primitive in places where that is necessary. A bare minimum std::atomic polyfill is added for OS X because Apple wouldn't be Apple if things just worked out of the box. PR-URL: https://github.com/nodejs/node/pull/3528 Reviewed-By:
Fedor Indutny <fedor@indutny.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Michaël Zasso authored
The current implementation overwrites the prototype of the target constructor. It is not allowed with ES2015 classes because the prototype property is read only. Use Object.setPrototypeOf instead. Fixes: https://github.com/nodejs/node/issues/3452 PR-URL: https://github.com/nodejs/node/pull/3455 Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
Sakthipriyan Vairamani authored
If the URL passed to `http{s}.request` or `http{s}.get` is not properly parsable by `url.parse`, we fall back to use `localhost` and port 80. This creates confusing error messages like in this question http://stackoverflow.com/q/32675907/1903116. This patch throws an error message, if `url.parse` fails to parse the URL properly. Previous Discussion: https://github.com/nodejs/node/pull/2966 PR-URL: https://github.com/nodejs/node/pull/2967 Reviewed-By:
Сковорода Никита Андреевич <chalkerx@gmail.com> Reviewed-By:
Evan Lucas <evanlucas@me.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
-
- Oct 26, 2015
-
-
Trevor Norris authored
Fixes: https://github.com/nodejs/node/issues/3497 PR-URL: https://github.com/nodejs/node/pull/3500 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Rod Vagg authored
Reviewed-By:
James M Snell <jasnell@gmail.com> PR-URL: https://github.com/nodejs/node/pull/3480
-
Shigeki Ohtsu authored
This fix is to be consistent implementation with ALPN. Tow NPN protocol data in the persistent memebers move to hidden variables in the wrap object. PR-URL: https://github.com/nodejs/node/pull/2564 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Shigeki Ohtsu authored
ALPN is added to tls according to RFC7301, which supersedes NPN. When the server receives both NPN and ALPN extensions from the client, ALPN takes precedence over NPN and the server does not send NPN extension to the client. alpnProtocol in TLSSocket always returns false when no selected protocol exists by ALPN. In https server, http/1.1 token is always set when no options.ALPNProtocols exists. PR-URL: https://github.com/nodejs/node/pull/2564 Reviewed-By:
Fedor Indutny <fedor@indutny.com> Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Michaël Zasso authored
inherits is used in lib and tests but its functionality itself is not tested yet. PR-URL: https://github.com/nodejs/node/pull/3507 Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
-
Evan Lucas authored
If the resulting buffer.toString() call in fs.read throws, catch the error and pass it back in the callback. This issue only presents itself when fs.read is called using the legacy string interface: fs.read(fd, length, position, encoding, callback) PR-URL: https://github.com/nodejs/node/pull/3503 Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-
Junliang Yan authored
The test sometimes fail on an assertion but no useful error message was generated for debugging. Modify the test to generate useful debugging message. PR-URL: https://github.com/nodejs/node/pull/3501 Reviewed-By:
Trevor Norris <trev.norris@gmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com>
-
Myles Borins authored
Currently there are many instances where assert.fail is directly passed to a callback for error handling. Unfortunately this will swallow the error as it is the third argument of assert.fail that sets the message not the first. This commit adds a new function to test/common.js that simply wraps assert.fail and calls it with the provided message. Tip of the hat to @trott for pointing me in the direction of this. PR-URL: https://github.com/nodejs/node/pull/3453 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Colin Ihrig <cjihrig@gmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com>
-
Evan Lucas authored
In fs.readFile, if an encoding is specified and toString fails, do not throw an error. Instead, pass the error to the callback. Fixes: https://github.com/nodejs/node/issues/2767 PR-URL: https://github.com/nodejs/node/pull/3485 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-
Ben Noordhuis authored
malloc(0) and realloc(ptr, 0) have implementation-defined behavior in that the standard allows them to either return a unique pointer or a nullptr for zero-sized allocation requests. Normalize by always using a nullptr. Fixes: https://github.com/nodejs/node/issues/3496 PR-URL: https://github.com/nodejs/node/pull/3499 Reviewed-By:
Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-
Ben Noordhuis authored
PR-URL: https://github.com/nodejs/node/pull/3478 Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-
Michael Dawson authored
This test is already partially disabled for several platforms with the comment that the required info is not provided at the C++ level. I'm adding AIX as and PPC BE linux as they currently fall into the same category. We are working to see if we can change that in v8 but it will be non-trivial if is possible at all so I don't want to leave the CI with failing tests until that point. PR-URL: https://github.com/nodejs/node/pull/3491 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com>
-
Michael Dawson authored
This PR is the first step enabling support for native modules for AIX. The main issue is that unlike linux where all symbols within the Node executable are available to the shared library for a native module (npm), on AIX the symbols must be explicitly exported. In addition, when the shared library is built it must be linked using a list of the available symbols. This patch covers the changes need to: 1) Export the symbols when building the node executable 2) Generate the file listing the symbols that can be used when building the shared library. For AIX, it breaks the build process into 2 steps. The first builds a static library and then generates a node.exp file which contains the symbols from that library. The second builds the node executable and uses the node.exp file to specify which symbols should be exported. In addition, it save the node.exp file so that it can later be used in the creation of the shared library when building a native module. The following additional steps will be required in dependent projects to fully enable AIX for native modules and are being worked separately: - Updates to node-gyp to use node.exp when creating the shared library for a native module - Fixes to gyp related to copying files as covered in https://codereview.chromium.org/1368133002/patch/1/10001 - Pulling in updated gyp versions to Node and node-gyp - Pulling latest libuv These changes were done to minimize the change to other platforms by working within the existing structure to add the 2 step process for AIX without changing the process for other platforms. PR-URL: https://github.com/nodejs/node/pull/3114 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Michaël Zasso authored
This update fixes a breaking regression in the date parser. Ref: https://code.google.com/p/chromium/issues/detail?id=539813 Ref: https://code.google.com/p/chromium/issues/detail?id=543320 PR-URL: https://github.com/nodejs/node/pull/3484 Reviewed-By:
Ben Noordhuis <info@bnoordhuis.nl>
-
Rebecca Turner authored
41923c0c broke things. This fixes them. Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Evan Lucas <evanlucas@me.com> PR-URL: https://github.com/nodejs/node/pull/3494
-
Marti Martz authored
* Add a simple example for buffer.concat * Change grammar slightly. Fixes: #3219 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Trevor Norris <trev.norris@gmail.com> PR-URL: https://github.com/nodejs/node/pull/3255
-
Michael Dawson authored
Pull in the change that has been committed to v8 master in https://codereview.chromium.org/1415463002/. We are currently cherry-picking into 4.6 and 4.7 but until next next v8 update into Node Master I'd like to float it as it will make PPC LE go green in the CI Fixes: https://github.com/nodejs/node/issues/3390 Reviewed-By:
James M Snell <jasnell@gmail.com> Reviewed-By:
Ben Noordhuis <ben@strongloop.com> PR-URL: https://github.com/nodejs/node/pull/3474
-
Rebecca Turner authored
PR-URL: https://github.com/nodejs/node/pull/3310 Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com>
-
- Oct 22, 2015
-
-
Jeremiah Senkpiel authored
Refs: https://github.com/nodejs/node/pull/3308 PR-URL: https://github.com/nodejs/node/pull/3489 Reviewed-By:
Rod Vagg <rod@vagg.org>
-
Rebecca Turner authored
Refs: https://github.com/nodejs/node/pull/3308 PR-URL: https://github.com/nodejs/node/pull/3489 Reviewed-By:
Rod Vagg <rod@vagg.org> Reviewed-By:
Jeremiah Senkpiel <fishrock123@rocketmail.com>
-
Jeremiah Senkpiel authored
Emitting 'close' before the history has flushed is somewhat incorrect and rather confusing. This also makes the 'close' event always asynchronous for consistency. Refs: https://github.com/nodejs/node/pull/2356 PR-URL: https://github.com/nodejs/node/pull/3435 Reviewed By: Evan Lucas <evanlucas@me.com> Reviewed-By:
Trevor Norris <trev.norris@gmail.com>
-