issue6291: some more cleanups