Changeset 1f242285 in rtems


Ignore:
Timestamp:
Aug 21, 2015, 3:25:37 AM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
c72f132
Parents:
151e53f
git-author:
Sebastian Huber <sebastian.huber@…> (08/21/15 03:25:37)
git-committer:
Sebastian Huber <sebastian.huber@…> (08/31/15 07:56:55)
Message:

posix: Avoid _RBTree_Next()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/posix/src/keyfreememory.c

    r151e53f r1f242285  
    3838   * find the smallest thread_id node in the rbtree.
    3939   */
    40   next = _RBTree_Next( iter, RBT_LEFT );
     40  next = _RBTree_Predecessor( iter );
    4141  p = POSIX_KEYS_RBTREE_NODE_TO_KEY_VALUE_PAIR( next );
    4242  while ( next != NULL && p->key == key_id) {
    4343    iter = next;
    44     next = _RBTree_Next( iter, RBT_LEFT );
     44    next = _RBTree_Predecessor( iter );
    4545    p = POSIX_KEYS_RBTREE_NODE_TO_KEY_VALUE_PAIR( next );
    4646  }
     
    5151  p = POSIX_KEYS_RBTREE_NODE_TO_KEY_VALUE_PAIR( iter );
    5252  while ( iter != NULL && p->key == key_id ) {
    53     next = _RBTree_Next( iter, RBT_RIGHT );
     53    next = _RBTree_Successor( iter );
    5454
    5555    _POSIX_Keys_Free_key_value_pair( p );
Note: See TracChangeset for help on using the changeset viewer.