diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2014-12-12 11:19:10 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2014-12-12 13:16:03 +0100 |
commit | dac340dd663bdfed29470c1327a2e7d10dbfa002 (patch) | |
tree | bd3acfbf94b5617d704bccd07de00179585d6fe0 /cpukit/posix/include/rtems/posix/keyimpl.h | |
parent | confdefs.h: Fix workspace size if idle task is FP (diff) | |
download | rtems-dac340dd663bdfed29470c1327a2e7d10dbfa002.tar.bz2 |
posix: Simplify _POSIX_Keys_Find()
Diffstat (limited to 'cpukit/posix/include/rtems/posix/keyimpl.h')
-rw-r--r-- | cpukit/posix/include/rtems/posix/keyimpl.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/cpukit/posix/include/rtems/posix/keyimpl.h b/cpukit/posix/include/rtems/posix/keyimpl.h index 42989b0c16..1dcfb4e9c6 100644 --- a/cpukit/posix/include/rtems/posix/keyimpl.h +++ b/cpukit/posix/include/rtems/posix/keyimpl.h @@ -169,17 +169,18 @@ RTEMS_INLINE_ROUTINE void _POSIX_Keys_Key_value_pair_free( } RTEMS_INLINE_ROUTINE RBTree_Node *_POSIX_Keys_Find( - pthread_key_t key, - Thread_Control *thread, - POSIX_Keys_Key_value_pair *search_node + pthread_key_t key, + Thread_Control *thread ) { - search_node->key = key; - search_node->thread = thread; + POSIX_Keys_Key_value_pair search_node; + + search_node.key = key; + search_node.thread = thread; return _RBTree_Find( &_POSIX_Keys_Key_value_lookup_tree, - &search_node->Key_value_lookup_node, + &search_node.Key_value_lookup_node, _POSIX_Keys_Key_value_compare, true ); |