more shared state fixes