fix gcc errors