Fix miscellaneous issues so it will pass -Wall