diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-06-17 12:58:31 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-06-17 12:58:31 +0000 |
commit | 42eabfcca25d988b764412e18c3dec5208864a7e (patch) | |
tree | c2b1ace3fde5cbf22135144ecd58e92c3726ee25 /thread_pthread.c | |
parent | a9934cb0982095dc68b2bf952775f658c2a691f8 (diff) | |
download | bundler-42eabfcca25d988b764412e18c3dec5208864a7e.tar.gz |
* thread_pthread.c (native_thread_init_stack): suppress warnings.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17380 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread_pthread.c')
-rw-r--r-- | thread_pthread.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/thread_pthread.c b/thread_pthread.c index 62ac28b808..bcab6acddb 100644 --- a/thread_pthread.c +++ b/thread_pthread.c @@ -229,13 +229,15 @@ native_thread_init_stack(rb_thread_t *th) else { #ifdef HAVE_PTHREAD_GETATTR_NP pthread_attr_t attr; + void *start; CHECK_ERR(pthread_getattr_np(curr, &attr)); # if defined HAVE_PTHREAD_ATTR_GETSTACK - CHECK_ERR(pthread_attr_getstack(&attr, &th->machine_stack_start, &th->machine_stack_maxsize)); + CHECK_ERR(pthread_attr_getstack(&attr, &start, &th->machine_stack_maxsize)); # elif defined HAVE_PTHREAD_ATTR_GETSTACKSIZE && defined HAVE_PTHREAD_ATTR_GETSTACKADDR - CHECK_ERR(pthread_attr_getstackaddr(&attr, &th->machine_stack_start)); + CHECK_ERR(pthread_attr_getstackaddr(&attr, &start)); CHECK_ERR(pthread_attr_getstacksize(&attr, &th->machine_stack_maxsize)); # endif + th->machine_stack_start = start; #else rb_raise(rb_eNotImpError, "ruby engine can initialize only in the main thread"); #endif |