OSState bug fix