Added -Wextra, fixed all associated warnings.