[PATCH v5 07/11] virParseOwnershipIds: Refactor