fixed a bunch of warnings
merged