Fix a few dialyzer bugs found by chef_index.