git.annexia.org
/
libguestfs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Version 1.3.16.
[libguestfs.git]
/
ocaml
/
guestfs_c.c
diff --git
a/ocaml/guestfs_c.c
b/ocaml/guestfs_c.c
index
62d42d3
..
f7d8dff
100644
(file)
--- a/
ocaml/guestfs_c.c
+++ b/
ocaml/guestfs_c.c
@@
-42,6
+42,10
@@
}while(0)
#endif
}while(0)
#endif
+/* These prototypes are solely to quiet gcc warning. */
+CAMLprim value ocaml_guestfs_create (void);
+CAMLprim value ocaml_guestfs_close (value gv);
+
/* Allocate handles and deal with finalization. */
static void
guestfs_finalize (value gv)
/* Allocate handles and deal with finalization. */
static void
guestfs_finalize (value gv)
@@
-89,6
+93,17
@@
ocaml_guestfs_raise_error (guestfs_h *g, const char *func)
CAMLnoreturn;
}
CAMLnoreturn;
}
+void
+ocaml_guestfs_raise_closed (const char *func)
+{
+ CAMLparam0 ();
+ CAMLlocal1 (v);
+
+ v = caml_copy_string (func);
+ caml_raise_with_arg (*caml_named_value ("ocaml_guestfs_closed"), v);
+ CAMLnoreturn;
+}
+
/* Guestfs.create */
CAMLprim value
ocaml_guestfs_create (void)
/* Guestfs.create */
CAMLprim value
ocaml_guestfs_create (void)