mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
thread_pthread.c: suppress warning
* thread_pthread.c (get_stack): define guard only when it is used. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36052 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
621153bf3f
commit
9341988b41
1 changed files with 2 additions and 0 deletions
|
@ -509,7 +509,9 @@ get_stack(void **addr, size_t *size)
|
|||
{int err = (expr); if (err) return err;}
|
||||
#if defined HAVE_PTHREAD_GETATTR_NP || defined HAVE_PTHREAD_ATTR_GET_NP
|
||||
pthread_attr_t attr;
|
||||
# if defined HAVE_PTHREAD_ATTR_GET_NP /* HAVE_PTHREAD_ATTR_GETGUARDSIZE */
|
||||
size_t guard = 0;
|
||||
# endif
|
||||
|
||||
# ifdef HAVE_PTHREAD_GETATTR_NP /* Linux */
|
||||
STACK_GROW_DIR_DETECTION;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue