platform: fixed return value from CCondition::Wait()