ia64/xen-unstable

changeset 4564:b07029dd30fa

bitkeeper revision 1.1159.258.103 (42642c5djs1dzMOSs-vIJLlGCQyrMQ)

Allow xc_domain_info_t to be optional in xc_domain_getfullinfo
From: Kip Macy
Signed-off-by: ian@xensource.com
author iap10@freefall.cl.cam.ac.uk
date Mon Apr 18 21:53:33 2005 +0000 (2005-04-18)
parents ec106abf799e
children 99aeb036036c
files tools/libxc/xc_domain.c
line diff
     1.1 --- a/tools/libxc/xc_domain.c	Mon Apr 18 21:35:16 2005 +0000
     1.2 +++ b/tools/libxc/xc_domain.c	Mon Apr 18 21:53:33 2005 +0000
     1.3 @@ -132,7 +132,8 @@ int xc_domain_getfullinfo(int xc_handle,
     1.4  
     1.5      rc = do_dom0_op(xc_handle, &op);
     1.6  
     1.7 -    memcpy(info, &op.u.getdomaininfo, sizeof(*info));
     1.8 +    if ( info )
     1.9 +        memcpy(info, &op.u.getdomaininfo, sizeof(*info));
    1.10  
    1.11      if ( ((u16)op.u.getdomaininfo.domain != domid) && rc > 0 )
    1.12          return -ESRCH;