Fix warnings spotted by -Wall