[Libvirt-cim] [PATCH 3 of 3] EAFP: adopt Device interface changes

Dan Smith danms at us.ibm.com
Fri Mar 7 16:32:03 UTC 2008


HE> # HG changeset patch
HE> # User Heidi Eckhart <heidieck at linux.vnet.ibm.com>
HE> # Date 1204892342 -3600
HE> # Node ID 50f47a071fb1d4668a5eb1b3e0c649f87ce8f376
HE> # Parent  366b317afbf382f85ed75b86b6df9eae30dd6c94
HE> EAFP: adopt Device interface changes

This patch is throwing a reject for me:

  src/Virt_ElementAllocatedFromPool.c
  Hunk #1 succeeded at 73 with fuzz 1 (offset -4 lines).
  Hunk #2 FAILED at 134.
  Hunk #4 succeeded at 168 with fuzz 2 (offset -2 lines).
  1 out of 4 hunks FAILED -- saving rejects to file src/Virt_ElementAllocatedFromPool.c.rej

The actual rejected hunk is:

  ***************
  *** 134,180 ****
            return dest->cur;
    }
    
  - static int devs_from_pool(uint16_t type,
  -                           const CMPIObjectPath *ref,
  -                           const char *poolid,
  -                           struct inst_list *list)
  - {
  -         CMPIStatus s;
  -         virConnectPtr conn = NULL;
  -         virDomainPtr *doms = NULL;
  -         int count;
  -         int i;
  -         const char *ns = NAMESPACE(ref);
  -         const char *cn = CLASSNAME(ref);
  - 
  -         conn = connect_by_classname(_BROKER, cn, &s);
  -         if (conn == NULL)
  -                 return 0;
  - 
  -         count = get_domain_list(conn, &doms);
  - 
  -         for (i = 0; i < count; i++) {
  -                 const char *name;
  -                 struct inst_list tmp;
  - 
  -                 inst_list_init(&tmp);
  - 
  -                 name = virDomainGetName(doms[i]);
  - 
  -                 dom_devices(_BROKER, doms[i], ns, type, &tmp);
  - 
  -                 filter_by_pool(list, &tmp, type, poolid);
  - 
  -                 inst_list_free(&tmp);
  -                 virDomainFree(doms[i]);
  -         }
  - 
  -         free(doms);
  -         virConnectClose(conn);
  - 
  -         return count;
  - }
  - 
    static CMPIStatus pool_to_vdev(const CMPIObjectPath *ref,
                                   struct std_assoc_info *info,
                                   struct inst_list *list)
  --- 134,139 ----
            return dest->cur;
    }
    
    static CMPIStatus pool_to_vdev(const CMPIObjectPath *ref,
                                   struct std_assoc_info *info,
                                   struct inst_list *list)
  
I applied this after this set:

  Update resource types to CIM_RES_TYPE_foo and Adopt changes to
  affected providers

Did I mess up the order?  Thanks!

-- 
Dan Smith
IBM Linux Technology Center
Open Hypervisor Team
email: danms at us.ibm.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 188 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvirt-cim/attachments/20080307/4c86cbf1/attachment.sig>


More information about the Libvirt-cim mailing list