fixes for gcc 3.4