On 02/12/2012 11:26 AM, 灵矫 wrote: [please don't top-post on technical lists] > Sorry, > I just add the function prototypes in libvirt.h libvirt.in<http://libvirt.in>, implement it in libvirt.c and call a hypervisor function in qemu_drivier.h. > basicly no other codes. It's easier to review your code for errors if you post the actual patches you have written so far. > > 2012/2/13 chang liu <lingjiao.lc@xxxxxxxxx<mailto:lingjiao.lc@xxxxxxxxx>> > hi all, > Sorry to disturb you. > I wanna to add a new api to get some sheepdog cluster info, but I has get this error, I don't know how to do. > > I have add a function to daemon/remote.c that call the libvirt.c 's api, remoteDispatchConnectExecuteCommand, and here i get the return value. > > struct remote_connect_execute_command_ret { > remote_nonnull_string ret_val; > }; > typedef struct remote_connect_execute_command_ret remote_connect_execute_command_ret; > > > static int > remoteDispatchConnectExecuteCommand (struct qemud_server *server ATTRIBUTE_UNUSED, > struct qemud_client *client ATTRIBUTE_UNUSED, > virConnectPtr conn, > remote_message_header *hdr ATTRIBUTE_UNUSED, > remote_error *rerr, > remote_connect_execute_command_args *args, > remote_connect_execute_command_ret *ret) If you're lucky, your new API won't need you to write any code in daemon/remote.c, but can instead be autogenerated as part of adding your new API to src/remote/remote_protocol.x. But it's hard to see what you might be doing wrong without seeing your full patch. -- Eric Blake eblake@xxxxxxxxxx +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list