Fix misc CS/WS issues reported in PR #198