bugfix for compilation with gnu