minor fixes for gcc compiler