Fix all warnings when using gcc 4.8.1