HE> @@ -673,177 +681,190 @@ static CMPIStatus diskpool_instance(virC
HE> return s;
HE> }
HE> -static CMPIStatus _get_pool(const CMPIBroker *broker,
HE> - virConnectPtr conn,
HE> - const char *type,
HE> +static CMPIStatus _get_pools(const CMPIBroker *broker,
HE> + const CMPIObjectPath *reference,
HE> + const uint16_t type,
HE> + const char *id,
HE> + struct inst_list *list)
HE> +{
HE> + CMPIStatus s = {CMPI_RC_OK, NULL};
HE> + virConnectPtr conn;
HE> +
HE> + conn = connect_by_classname(broker, CLASSNAME(reference), &s);
HE> + if (conn == NULL)
HE> + goto out;
HE> +
HE> + if ((type == CIM_POOL_TYPE_PROC) ||
HE> + (type == CIM_TYPE_ALL))
HE> + s = procpool_instance(conn, list,
HE> + NAMESPACE(reference),
HE> + id, broker);
HE> +
HE> + if ((type == CIM_POOL_TYPE_MEM) ||
HE> + (type == CIM_TYPE_ALL))
HE> + s = mempool_instance(conn, list,
HE> + NAMESPACE(reference),
HE> + id, broker);
HE> +
HE> + if ((type == CIM_POOL_TYPE_NET) ||
HE> + (type == CIM_TYPE_ALL))
HE> + s = netpool_instance(conn, list,
HE> + NAMESPACE(reference),
HE> + id, broker);
HE> +
HE> + if ((type == CIM_POOL_TYPE_DISK) ||
HE> + (type == CIM_TYPE_ALL))
HE> + s = diskpool_instance(conn, list,
HE> + NAMESPACE(reference),
HE> + id, broker);
HE> +
HE> + if (type == CIM_POOL_TYPE_UNKNOWN)
HE> + cu_statusf(broker, &s,
HE> + CMPI_RC_ERR_NOT_FOUND,
HE> + "No such instance - resource pool type
unknow.");
^^^^^^^
You're missing an 'n' there, and the period should be removed.
HE> + if (id && list->cur == 0)
HE> + cu_statusf(broker, &s,
HE> + CMPI_RC_ERR_NOT_FOUND,
HE> + "No such instance (%s).", id);
As well as this period.
--
Dan Smith
IBM Linux Technology Center
Open Hypervisor Team
email: danms(a)us.ibm.com