Changeset 68c156a in rtems


Ignore:
Timestamp:
Apr 3, 2014, 8:03:42 PM (5 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.11, master
Children:
3a422f7d
Parents:
a0a073d1
Message:

pthreadcreate.c: Fix bug where attr used instead of the_attr

File:
1 edited

Legend:

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

    ra0a073d1 r68c156a  
    1010 */
    1111
    12 /*  COPYRIGHT (c) 1989-2008.
     12/*
     13 *  COPYRIGHT (c) 1989-2014.
    1314 *  On-Line Applications Research Corporation (OAR).
    1415 *
     
    143144#if __RTEMS_HAVE_SYS_CPUSET_H__
    144145  status = _CPU_set_Is_valid( the_attr->affinityset, the_attr->affinitysetsize );
    145   if (!status )
     146  if ( !status )
    146147    return EINVAL;
    147148#endif
     
    192193  }
    193194
    194 #if defined(RTEMS_SMP)
    195 #if __RTEMS_HAVE_SYS_CPUSET_H__
    196    status = _Scheduler_Set_affinity(
    197      the_thread, 
    198      attr->affinitysetsize,
    199      attr->affinityset
     195#if defined(RTEMS_SMP) && __RTEMS_HAVE_SYS_CPUSET_H__
     196   status = _Scheduler_Set_affinity(
     197     the_thread,
     198     the_attr->affinitysetsize,
     199     the_attr->affinityset
    200200   );
    201   if ( !status ) {
    202     _POSIX_Threads_Free( the_thread );
    203     _RTEMS_Unlock_allocator();
    204     return EINVAL;
    205   }
    206 #endif
     201   if ( !status ) {
     202     _POSIX_Threads_Free( the_thread );
     203     _RTEMS_Unlock_allocator();
     204     return EINVAL;
     205   }
    207206#endif
    208207
Note: See TracChangeset for help on using the changeset viewer.