Scott Blomquist
f657ce685d
windows: add tracing with performance counters
...
Patch by Henry Rawas and Scott Blomquist.
2012-11-21 01:21:53 +01:00
Sergey Kholodilov
019ad346e0
crypto: fix ssl error handling
...
Make HandleSSLError() correctly process a zero status code: sometimes it
indicates an error and sometimes it doesn't.
2012-11-17 00:52:58 +01:00
Ben Noordhuis
71ba7bc2a0
node: remove eio-emul.h
...
The purpose of this file was to remap the old libeio API to the new one.
We dropped libeio in ee77a6a and this file has been broken ever since.
Ergo, remove it.
2012-11-16 23:44:44 +01:00
Nathan Rajlich
5e4e87ade5
os: add os.endianness() function
2012-11-08 12:31:45 -08:00
Joshua Erickson
fb6377ebd0
net: More accurate IP address validation and IPv6 dotted notation.
...
* Added isIP method to make use of inet_pton to cares_wrap.cc
* Modified net.isIP() to make use of new C++ isIP method.
* Added new tests to test-net-isip.js.
2012-11-06 16:49:21 +01:00
Anthony Pesch
fddb5dc2d3
typed arrays: add slice() support to ArrayBuffer
2012-11-06 00:13:26 +01:00
Scott Blomquist
66f64ae072
windows: generate ETW events to track v8 compiled code positions
...
Patch by Henry Rawas and Scott Blomquist.
2012-11-01 14:06:26 +01:00
Jan Wynholds
06810b29fa
tracing: add systemtap support
2012-11-01 01:25:22 +01:00
isaacs
07d3b21f43
zlib: s/clear/close/ and match other close() semantics
2012-10-31 16:56:30 -07:00
Ben Noordhuis
a93424da4a
zlib: pass object size hint to V8
...
Inform V8 that the zlib context object is tied to a large off-heap buffer.
This makes the GC run more often (in theory) and improves the accuracy of
--trace_external_memory.
2012-10-30 15:03:27 +01:00
Ben Noordhuis
570e4be932
zlib: reduce memory consumption, release early
...
In zlibBuffer(), don't wait for the garbage collector to reclaim the zlib memory
but release it manually. Reduces memory consumption by a factor of 10 or more
with some workloads.
Test case:
function f() {
require('zlib').deflate('xxx', g);
}
function g() {
setTimeout(f, 5);
}
f();
Observe RSS memory usage with and without this commit. After 10,000 iterations,
RSS stabilizes at ~35 MB with this commit. Without, RSS is over 300 MB and keeps
growing.
Cause: whenever the JS object heap hits the high-water mark, the V8 GC sweeps
it clean, then tries to grow it in order to avoid more sweeps in the near
future. Rule of thumb: the bigger the JS heap, the lazier the GC can be.
A side effect of a bigger heap is that objects now live longer. This is harmless
in general but it affects zlib context objects because those are tied to large
buffers that live outside the JS heap, on the order of 16K per context object.
Ergo, don't wait for the GC to reclaim the memory - it may take a long time.
Fixes #4172 .
2012-10-30 15:03:17 +01:00
isaacs
21c741f257
Print warning when maxTickDepth is reached
2012-10-29 10:53:39 -07:00
isaacs
78dbb15858
Now working on v0.9.4
2012-10-24 10:10:57 -07:00
isaacs
1ed4c6776e
2012.10.24, Version 0.9.3 (Unstable)
...
* V8: Upgrade to 3.13.7.4
* crypto: Default to buffers instead of binary strings (isaacs, Fedor Indutny)
* crypto: add getHashes() and getCiphers() (Ben Noordhuis)
* unix: add custom thread pool, remove libeio (Ben Noordhuis)
* util: make `inspect()` accept an "options" argument (Nathan Rajlich)
* https: fix renegotation attack protection (Ben Noordhuis)
* cluster: make 'listening' handler see actual port (Aaditya Bhatia)
* windows: use USERPROFILE to get the user's home dir (Bert Belder)
* path: add platform specific path delimiter (Paul Serby)
* http: add response.headersSent property (Pavel Lang)
* child_process: make .fork()'d child auto-exit (Ben Noordhuis)
* events: add 'removeListener' event (Ben Noordhuis)
* string_decoder: Add 'end' method, do base64 properly (isaacs)
* buffer: include encoding value in exception when invalid (Ricky Ng-Adam)
* http: make http.ServerResponse no longer emit 'end' (isaacs)
* streams: fix pipe is destructed by 'end' from destination (koichik)
2012-10-24 09:21:44 -07:00
isaacs
1122e3af28
crypto: Style. Prefer 'char*' over 'char *'
2012-10-23 10:48:51 -07:00
isaacs
f2fa97f178
crypto: Remove many unnecessary toObjects
2012-10-23 10:48:51 -07:00
isaacs
c87b524c5f
crypto: Clean up buffer handling and DH methods
2012-10-23 10:48:51 -07:00
isaacs
bfb9d5bbe6
crypto: Binding only accepts buffers
2012-10-23 10:48:50 -07:00
isaacs
18beea4a3f
Merge remote-tracking branch 'ry/v0.8'
2012-10-23 08:22:47 -07:00
Aaron Jacobs
49f0f618a9
typed arrays: use signed char for signed int8s
...
The C standard allows plain `char` to be unsigned. The build environment
at Google trips this issue.
2012-10-23 16:55:59 +02:00
Ben Noordhuis
844a0058d0
crypto: fix DH use-after-free and memory leak
...
Fix a use-after-free bug and a memory leak in the error path of
DiffieHellman::ComputeSecret().
* the BIGNUM key was used after being freed with BN_free().
* the output buffer was not freed
2012-10-22 00:20:45 +02:00
Ben Noordhuis
de18e29784
crypto: fix DH 1 byte buffer underflow
...
Passing a bad key to DiffieHellman::ComputeSecret() made it zero the byte
before the heap allocated buffer due to an erroneous size calculation.
2012-10-22 00:20:32 +02:00
Ben Noordhuis
cb6d084d35
node: update description of --print
2012-10-20 15:03:48 +02:00
Nathan Rajlich
4b238b4c2a
Merge remote-tracking branch 'origin/v0.8'
...
Conflicts:
AUTHORS
ChangeLog
deps/uv/test/runner-win.c
doc/api/process.markdown
lib/repl.js
src/node_crypto.cc
src/node_version.h
2012-10-13 16:16:56 -07:00
Dean McNamee
47643d2ec5
typed arrays: remove unnecessary special-casing
...
Uint32Value() on undefined is equal to 0, no need to special case it.
2012-10-14 00:57:09 +02:00
Dean McNamee
93efc7f78d
typed arrays: simplify typed array get() and set()
...
Instead of duplicating V8's logic (including clamping), just simply call into
V8's Get() and Set() methods, which handles all conversions and typing.
2012-10-14 00:54:20 +02:00
Ben Noordhuis
14a6c4efb8
crypto: add crypto.getHashes()
2012-10-13 02:55:14 +02:00
Ben Noordhuis
f53441ab1f
crypto: add crypto.getCiphers()
...
Returns a list of, unsurprisingly, the available ciphers.
2012-10-13 01:49:57 +02:00
isaacs
58db21e6c5
Now working on 0.8.13
2012-10-12 08:57:25 -07:00
isaacs
38c72d4e29
2012.10.12, Version 0.8.12 (Stable)
...
* npm: Upgrade to 1.1.63
* crypto: Reduce stability index to 2-Unstable (isaacs)
* windows: fix handle leak in uv_fs_utime (Bert Belder)
* windows: fix application crashed popup in debug version (Bert Belder)
* buffer: report proper retained size in profiler (Ben Noordhuis)
* buffer: fix byteLength with UTF-16LE (koichik)
* repl: make "end of input" JSON.parse() errors throw in the REPL (Nathan Rajlich)
* repl: make invalid RegExp modifiers throw in the REPL (Nathan Rajlich)
* http: handle multiple Proxy-Authenticate values (Willi Eggeling)
2012-10-11 14:34:11 -07:00
Ben Noordhuis
6a128e037e
buffer: report proper retained size in profiler
...
Make buffers report the proper retained size in heap snapshots.
Before this commit, Buffer objects would show up in the heap profiler as being
only a few hundred bytes large, even if the actual buffer was many megabytes.
2012-10-11 01:05:18 +02:00
Ben Noordhuis
eec8c2edaf
crypto: fix -Wtautological-compare warning
2012-10-09 00:46:51 +02:00
Andrew Paprocki
8c5f269f90
Fix -Wsizeof-array-argument compiler warning.
2012-10-07 23:22:31 +02:00
koichik
fbb0ee6f24
buffer: fix byteLength with UTF-16LE
...
Fixes #4075 .
2012-10-04 18:18:15 +09:00
Ben Noordhuis
109f8e2773
node_http_parser: fix whitespace errors
2012-10-02 14:50:25 +02:00
isaacs
ae40f1c438
Merge remote-tracking branch 'ry/v0.8' into v0.8-merge
...
Conflicts:
AUTHORS
ChangeLog
deps/openssl/openssl.gyp
deps/uv/src/unix/linux/linux-core.c
deps/uv/src/unix/process.c
deps/uv/src/unix/stream.c
deps/v8/src/arm/builtins-arm.cc
deps/v8/src/arm/code-stubs-arm.cc
deps/v8/src/arm/full-codegen-arm.cc
lib/tls.js
src/node_version.h
test/simple/test-http-client-timeout-agent.js
2012-09-28 09:47:48 -07:00
isaacs
9877b8f414
Now working on 0.8.12
2012-09-27 10:25:12 -07:00
isaacs
e1f39468fa
2012.09.27, Version 0.8.11 (Stable)
...
* fs: Fix stat() size reporting for large files (Ben Noordhuis)
2012-09-27 09:39:23 -07:00
Ben Noordhuis
ec03c47c19
fs: fix stat() reporting for large files
...
Use Number::New(), not Integer::New(). Large values won't fit in an Integer.
Apply to the size, ino and blocks fields.
2012-09-26 01:20:56 +02:00
isaacs
37869f1c9a
Now working on 0.8.11
2012-09-25 15:36:10 -07:00
isaacs
0bc273da4f
2012.09.25, Version 0.8.10 (Stable)
...
* npm: Upgrade to 1.1.62
* repl: make invalid RegExps throw in the REPL (Nathan Rajlich)
* v8: loosen artificial mmap constraint (Bryan Cantrill)
* process: fix setuid() and setgid() error reporting (Ben Noordhuis)
* domain: Properly exit() on domain disposal (isaacs)
* fs: fix watchFile() missing deletion events (Ben Noordhuis)
* fs: fix assert in fs.watch() (Ben Noordhuis)
* fs: don't segfault on deeply recursive stat() (Ben Noordhuis)
* http: Remove timeout handler when data arrives (Frédéric Germain)
* http: make the client "res" object gets the same domain as "req" (Nathan Rajlich)
* windows: don't blow up when an invalid FD is used (Bert Belder)
* unix: map EDQUOT to UV_ENOSPC (Charlie McConnell)
* linux: improve /proc/cpuinfo parser (Ben Noordhuis)
* win/tty: reset background brightness when color is set to default (Bert Belder)
* unix: put child process stdio fds in blocking mode (Ben Noordhuis)
* unix: fix EMFILE busy loop (Ben Noordhuis)
* sunos: don't set TCP_KEEPALIVE (Ben Noordhuis)
* tls: Use slab allocator for memory management (Fedor Indutny)
* openssl: Use optimized assembly code for x86 and x64 (Bert Belder)
2012-09-25 13:48:15 -07:00
Ben Noordhuis
17ef062db1
handle_wrap: don't abort if wrap == NULL
...
After a disconnect, the internal pointer of the parent/child channel is set to
NULL. That's not an error so don't abort().
2012-09-22 03:49:17 +02:00
Fedor Indutny
63ff449d87
crypto: bring module into modern age
...
Introduce 'buffer' encoding, allow returning and giving buffers as
arguments of 'crypto' routines.
Fix #3278
2012-09-18 10:58:37 +04:00
isaacs
d406a8250f
Now working on v0.9.3
2012-09-17 18:34:48 -07:00
isaacs
6e20558890
2012.09.17, Version 0.9.2 (Unstable)
...
* http_parser: upgrade to ad3b631
* openssl: upgrade 1.0.1c
* darwin: use FSEvents to watch directory changes (Fedor Indutny)
* unix: support missing API on NetBSD (Shigeki Ohtsu)
* unix: fix EMFILE busy loop (Ben Noordhuis)
* windows: un-break writable tty handles (Bert Belder)
* windows: map WSAESHUTDOWN to UV_EPIPE (Bert Belder)
* windows: make spawn with custom environment work again (Bert Belder)
* windows: map ERROR_DIRECTORY to UV_ENOENT (Bert Belder)
* tls, https: validate server certificate by default (Ben Noordhuis)
* tls, https: throw exception on missing key/cert (Ben Noordhuis)
* tls: async session storage (Fedor Indutny)
* installer: don't install header files (Ben Noordhuis)
* buffer: implement Buffer.prototype.toJSON() (Nathan Rajlich)
* buffer: added support for writing NaN and Infinity (koichik)
* http: make http.ServerResponse emit 'end' (Ben Noordhuis)
* build: ./configure --ninja (Ben Noordhuis, Timothy J Fontaine)
* installer: fix --without-npm (Ben Noordhuis)
* cli: make -p equivalent to -pe (Ben Noordhuis)
* url: Go much faster by using Url class (isaacs)
2012-09-17 17:54:59 -07:00
Ben Noordhuis
96ca59fbf3
process: fix setuid() and setgid() error reporting
...
Zero errno before calling getgrnam_r() or getpwnam_r(). If errno had previously
been clobbered, node would report the wrong error.
2012-09-17 07:20:47 +02:00
Ben Noordhuis
db5c26e3b5
fs: fix assert in fs.watch()
...
Fix the following error:
FSEventWrap: Aborting due to unwrap failure at ../../src/fs_event_wrap.cc:169
It's possible and legal for a handle to be closed twice. HandleWrap::Close()
deals with that by ignoring the second close. Now FSEventWrap::Close() does
too.
Fixes #3997 .
2012-09-14 02:37:51 +02:00
Ben Noordhuis
07804c7c9a
fs: don't segfault on deeply recursive stat()
...
Check that the calls to Integer::New() and Date::New() succeed and bail out if
they don't.
V8 returns an empty handle on stack overflow. Trying to set the empty handle as
a property on an object results in a NULL pointer dereference in release builds
and an assert in debug builds.
Fixes #4015 .
2012-09-14 02:37:51 +02:00
Pavel Lang
7ab4a77d6f
buffer: update constructor prototype
...
Change Buffer::New(char*, size_t) to Buffer::New(const char*, size_t).
2012-09-13 16:31:04 +02:00
Ben Noordhuis
bec863b7de
crypto: use uv_thread_self()
2012-09-13 16:20:36 +02:00