X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=ocaml%2Fguestfs_c_actions.c;h=fa352fcce37b1971c4bb35df23bea2cfe7f5b352;hb=d5709ba3fd9b666012926e0a2a7e36107433eb98;hp=a707897af0c0908db3223a1a67cd6976b2732fd1;hpb=0faa5dde7b992ba11bb88f77b3424676c7c492e4;p=libguestfs.git diff --git a/ocaml/guestfs_c_actions.c b/ocaml/guestfs_c_actions.c index a707897..fa352fc 100644 --- a/ocaml/guestfs_c_actions.c +++ b/ocaml/guestfs_c_actions.c @@ -800,6 +800,28 @@ ocaml_guestfs_set_ready (value gv) } CAMLprim value +ocaml_guestfs_end_busy (value gv) +{ + CAMLparam1 (gv); + CAMLlocal1 (rv); + + guestfs_h *g = Guestfs_val (gv); + if (g == NULL) + caml_failwith ("end_busy: used handle after closing it"); + + int r; + + caml_enter_blocking_section (); + r = guestfs_end_busy (g); + caml_leave_blocking_section (); + if (r == -1) + ocaml_guestfs_raise_error (g, "end_busy"); + + rv = Val_unit; + CAMLreturn (rv); +} + +CAMLprim value ocaml_guestfs_mount (value gv, value devicev, value mountpointv) { CAMLparam3 (gv, devicev, mountpointv);