A bug in the _CORE_semaphore_Surrender()?

Sergei Organov osv at topconrd.ru
Tue Jul 1 14:49:27 UTC 2003


rtems-ss-20030128/cpukit/score/src/coresemsurrender.c:65:
      if ( the_semaphore->count <= the_semaphore->Attributes.maximum_count )
        the_semaphore->count += 1;

It seems that there should be '<' instead of '<=' in comparison, otherwise
semaphore 'count' could exceed 'Attributes.maximum_count', right? Seems like a
bug to me.

-- 
Sergei.




More information about the users mailing list