Eliminated many compiler warnings