Documentation errors for TSemaphore...

From: Konstantin Olchanski <olchansk_at_triumf.ca>
Date: Fri, 2 Nov 2007 18:48:13 -0700

Hello, there! I am trying to use a TSemaphore and I see following errors in the documentation:

  1. Post() method reads: "If any threads are blocked in Wait(), wake one of them up. Otherwise increment the value of the semaphore.". This implies that the semaphore value is not incremented if a waiting thread as awaken. Code inspection shows that the semphore value is always incremented.
  2. The return value for Wait() is not documented. Code inspection shows that it probably returns 0 when the semaphore is successfully acquired, but it is not obvious what other values may be returned.
-- 
Konstantin Olchanski
Data Acquisition Systems: The Bytes Must Flow!
Email: olchansk-at-triumf-dot-ca
Snail mail: 4004 Wesbrook Mall, TRIUMF, Vancouver, B.C., V6T 2A3, Canada
Received on Sat Nov 03 2007 - 02:48:34 CET

This archive was generated by hypermail 2.2.0 : Mon Nov 05 2007 - 05:50:02 CET