Fix warning handling