[libvirt] [libvirt-glib 2/3] Correct docs for gir_domain_save*()

Christophe Fergeau cfergeau at redhat.com
Fri Feb 17 10:49:06 UTC 2012


On Thu, Feb 16, 2012 at 05:49:47PM +0200, Zeeshan Ali (Khattak) wrote:
> From: "Zeeshan Ali (Khattak)" <zeeshanak at gnome.org>
> 
> A saved domain is stopped/shutdown on a successful save operation, not
> suspended.

libvirt documentation for virDomainManagedSave says "suspend", this should
be fixed there too.

> ---
>  libvirt-gobject/libvirt-gobject-domain.c |   16 ++++++++--------
>  1 files changed, 8 insertions(+), 8 deletions(-)
> 
> diff --git a/libvirt-gobject/libvirt-gobject-domain.c b/libvirt-gobject/libvirt-gobject-domain.c
> index d9e4c00..3eb5942 100644
> --- a/libvirt-gobject/libvirt-gobject-domain.c
> +++ b/libvirt-gobject/libvirt-gobject-domain.c
> @@ -731,15 +731,15 @@ cleanup:
>  
>  /**
>   * gvir_domain_save:
> - * @dom: the domain to save and suspend
> + * @dom: the domain to save
>   * @flags: extra flags, currently unused
>   * @err: Place-holder for possible errors
>   *
> - * Just like #gvir_domain_suspend but also saves the state of the domain on disk
> - * and therefore makes it possible to restore the domain to its previous state
> + * Saves the state of the domain on disk and stops it. Use #gvir_domain_resume
> + * to restore the saved state of the domain. A saved domain can be restored
>   * even after shutdown/reboot of host machine.
>   *
> - * Returns: TRUE if domain was saved and suspended successfully, FALSE otherwise.
> + * Returns: TRUE if domain was saved successfully, FALSE otherwise.
>   */
>  gboolean gvir_domain_save (GVirDomain *dom,
>                             unsigned int flags,
> @@ -750,7 +750,7 @@ gboolean gvir_domain_save (GVirDomain *dom,
>      if (virDomainManagedSave(dom->priv->handle, flags) < 0) {
>          gvir_set_error_literal(err, GVIR_DOMAIN_ERROR,
>                                 0,
> -                               "Unable to save and suspend domain");
> +                               "Unable to save domain");
>          return FALSE;
>      }
>  
> @@ -783,7 +783,7 @@ gvir_domain_save_helper(GSimpleAsyncResult *res,
>  
>  /**
>   * gir_domain_save_async:
> - * @dom: the domain to save and suspend
> + * @dom: the domain to save
>   * @flags: extra flags, currently unused
>   * @cancellable: (allow-none)(transfer none): cancellation object
>   * @callback: (scope async): completion callback
> @@ -819,13 +819,13 @@ void gvir_domain_save_async (GVirDomain *dom,
>  
>  /**
>   * gir_domain_save_finish:
> - * @dom: the domain to save and suspend
> + * @dom: the domain to save
>   * @result: (transfer none): async method result
>   * @err: Place-holder for possible errors
>   *
>   * Finishes the operation started by #gvir_domain_save_async.
>   *
> - * Returns: TRUE if domain was saved and suspended successfully, FALSE otherwise.
> + * Returns: TRUE if domain was saved successfully, FALSE otherwise.
>   */
>  gboolean gvir_domain_save_finish (GVirDomain *dom,
>                                    GAsyncResult *result,
> -- 
> 1.7.7.6
> 
> --
> libvir-list mailing list
> libvir-list at redhat.com
> https://www.redhat.com/mailman/listinfo/libvir-list
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120217/0ed28ba6/attachment-0001.sig>


More information about the libvir-list mailing list