Cleanups, fix warnings