fixed warnings, cleanup