X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=blobdiff_plain;f=guestfs.pod;h=b0fa5f29a7c75738414ca02b5e6ea415c2a42151;hp=1791545fbff9e63700f1a7683cab447a27eaf56a;hb=11d20e2b9f7dc1becba30d16c378c704a3ad1f50;hpb=82dd4b8a308dc97acabf37551bb780434f5e497a diff --git a/guestfs.pod b/guestfs.pod index 1791545..b0fa5f2 100644 --- a/guestfs.pod +++ b/guestfs.pod @@ -129,6 +129,12 @@ STATE MACHINE AND LOW-LEVEL EVENT API below. You should call these two functions after configuring the handle (eg. adding drives) but before performing any actions. +=head2 guestfs_kill_subprocess + + int guestfs_kill_subprocess (guestfs_h *handle); + +This kills the qemu subprocess. You should never need to call this. + =head1 CONFIGURATION MANAGEMENT The configuration functions allow you to configure which drive images @@ -189,7 +195,9 @@ handler using C. =head2 guestfs_set_error_handler - typedef void (*guestfs_error_handler_cb) (void *data, const char *msg); + typedef void (*guestfs_error_handler_cb) (guestfs_h *handle, + void *data, + const char *msg); void guestfs_set_error_handler (guestfs_h *handle, guestfs_error_handler_cb cb, void *data); @@ -205,7 +213,8 @@ message is completely discarded. =head2 guestfs_get_error_handler - guestfs_error_handler_cb guestfs_get_error_handler (guestfs_h *handle); + guestfs_error_handler_cb guestfs_get_error_handler (guestfs_h *handle, + void **data_rtn); Returns the current error handler callback. @@ -408,9 +417,9 @@ For example: /* returns immediately */ } - my_cb (guestfs_h *handle, void *data) + my_cb (guestfs_h *handle, void *data, XDR *xdr) { - retval = guestfs_nb_[action]_r (handle); + retval = guestfs_nb_[action]_r (handle, xdr); /* ... */ } @@ -420,6 +429,7 @@ high-level API. =head2 guestfs_set_reply_callback + typedef void (*guestfs_reply_cb) (guestfs_h *g, void *opaque, XDR *xdr); void guestfs_set_reply_callback (guestfs_h *handle, guestfs_reply_cb cb, void *opaque); @@ -428,11 +438,10 @@ The callback function C will be called whenever a reply is received from the child process. (This corresponds to a transition from the BUSY state to the READY state). -Note (I) that high-level API calls overwrite this -callback. - =head2 guestfs_set_log_message_callback + typedef void (*guestfs_log_message_cb) (guestfs_h *g, void *opaque, + char *buf, int len); void guestfs_set_log_message_callback (guestfs_h *handle, guestfs_log_message_cb cb, void *opaque); @@ -447,6 +456,7 @@ discarded. =head2 guestfs_set_subprocess_quit_callback + typedef void (*guestfs_subprocess_quit_cb) (guestfs_h *g, void *opaque); void guestfs_set_subprocess_quit_callback (guestfs_h *handle, guestfs_subprocess_quit_cb cb, void *opaque); @@ -458,6 +468,7 @@ any state to the CONFIG state). =head2 guestfs_set_launch_done_callback + typedef void (*guestfs_launch_done_cb) (guestfs_h *g, void *opaque); void guestfs_set_launch_done_callback (guestfs_h *handle, guestfs_ready_cb cb, void *opaque); @@ -477,9 +488,9 @@ two are provided for you: =over 4 -=item libguestfs-poll +=item libguestfs-select -A simple main loop that is implemented using L. +A simple main loop that is implemented using L. This is the default main loop unless you call C or C. @@ -556,8 +567,8 @@ function, eg. C. In those cases, ignore this call. =head2 WRITING A CUSTOM MAIN LOOP -This isn't documented. Please see the libguestfs-poll and libguestfs-glib -implementations. +This isn't documented. Please see the libguestfs-select and +libguestfs-glib implementations. =head1 SEE ALSO