summaryrefslogtreecommitdiffstats
path: root/sparsify
diff options
context:
space:
mode:
authorRichard W.M. Jones <rjones@redhat.com>2012-07-03 13:22:45 +0100
committerRichard W.M. Jones <rjones@redhat.com>2012-07-06 17:36:30 +0100
commita659f2c316fa8a959a6286f214e50911253c5580 (patch)
tree13d0855bd80fa6e37ae18d719623ac48bdd644a2 /sparsify
parent59e7179c3c8cebee792be9c86481cdc214ad4466 (diff)
downloadlibguestfs-a659f2c316fa8a959a6286f214e50911253c5580.tar.gz
libguestfs-a659f2c316fa8a959a6286f214e50911253c5580.tar.xz
libguestfs-a659f2c316fa8a959a6286f214e50911253c5580.zip
New API: guestfs_shutdown: Cleanly shutdown the backend.
The new API splits orderly close into a two-step process: if (guestfs_shutdown (g) == -1) { /* handle the error, eg. qemu error */ } guestfs_close (g); Note that the explicit shutdown step is only necessary in the case where you have made changes to the disk image and want to handle write errors. Read the documentation for further information. This change also: - deprecates guestfs_kill_subprocess - turns guestfs_kill_subprocess into the same as guestfs_shutdown - changes guestfish and other tools to call shutdown + close where necessary (not for read-only tools) - updates documentation - updates examples (cherry picked from commit ffbf1475f7ae7c462db289ad4834391469e72edd)
Diffstat (limited to 'sparsify')
-rw-r--r--sparsify/sparsify.ml1
1 files changed, 1 insertions, 0 deletions
diff --git a/sparsify/sparsify.ml b/sparsify/sparsify.ml
index 600a9e5f..733b7b7d 100644
--- a/sparsify/sparsify.ml
+++ b/sparsify/sparsify.ml
@@ -295,6 +295,7 @@ let () =
(* Don't need libguestfs now. *)
let () =
+ g#shutdown ();
g#close ()
(* What should the output format be? If the user specified an