aboutsummaryrefslogtreecommitdiff
path: root/deps/uv/test/test-thread.c
diff options
context:
space:
mode:
authorSaúl Ibarra Corretgé <saghul@gmail.com>2016-04-01 11:19:19 +0200
committerSaúl Ibarra Corretgé <saghul@gmail.com>2016-04-07 10:48:27 -0300
commitc3cec1eefc9f3b55a3fb7bd623b3d921f493870d (patch)
tree8a4defa8165e15d3d2afd331f2b04c90c70d5bb6 /deps/uv/test/test-thread.c
parent71544c5ecae20123a328e08a04b7f1587c4cdbbd (diff)
downloadandroid-node-v8-c3cec1eefc9f3b55a3fb7bd623b3d921f493870d.tar.gz
android-node-v8-c3cec1eefc9f3b55a3fb7bd623b3d921f493870d.tar.bz2
android-node-v8-c3cec1eefc9f3b55a3fb7bd623b3d921f493870d.zip
deps: upgrade libuv to 1.9.0
Fixes: https://github.com/nodejs/node/issues/5737 Fixes: https://github.com/nodejs/node/issues/4643 Fixes: https://github.com/nodejs/node/issues/4291 Fixes: https://github.com/nodejs/node-v0.x-archive/issues/8960 Refs: https://github.com/nodejs/node/pull/3594 PR-URL: https://github.com/nodejs/node/pull/5994 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Diffstat (limited to 'deps/uv/test/test-thread.c')
-rw-r--r--deps/uv/test/test-thread.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/deps/uv/test/test-thread.c b/deps/uv/test/test-thread.c
index 7f3321aa06..10bec3fe6c 100644
--- a/deps/uv/test/test-thread.c
+++ b/deps/uv/test/test-thread.c
@@ -209,3 +209,24 @@ TEST_IMPL(thread_local_storage) {
uv_key_delete(&tls_key);
return 0;
}
+
+
+#if defined(__APPLE__)
+static void thread_check_stack(void* arg) {
+ /* 512KB is the default stack size of threads other than the main thread
+ * on OSX. */
+ ASSERT(pthread_get_stacksize_np(pthread_self()) > 512*1024);
+}
+#endif
+
+
+TEST_IMPL(thread_stack_size) {
+#if defined(__APPLE__)
+ uv_thread_t thread;
+ ASSERT(0 == uv_thread_create(&thread, thread_check_stack, NULL));
+ ASSERT(0 == uv_thread_join(&thread));
+ return 0;
+#else
+ RETURN_SKIP("OSX only test");
+#endif
+}