removed general compiler warnings from gcc and msvc