some warning fixes and minor cleanups

Change-Id: Ic1ca0e6a7e2b989250022382cf59960fd8da9ddf