Fix a bunch of dialyzer warnings.