#1248: Fix notices and strict warnings