GCC fixes (now compiles under GCC 4.8 again)