bugfixes to remove warnings from build check