Catching warnings during resize