boost::optional usage fixes.