Fixes for newer gcc version