[libvirt] [PATCH 5/6] libvirt.c: indent code of virDomainGetMemoryParameters's documentation

Claudio Bley cbley at av-test.de
Wed Sep 25 06:49:08 UTC 2013


By indenting code inside of comments, it gets recognized as a
code block when generating the HTML documentation.

Signed-off-by: Claudio Bley <cbley at av-test.de>
---
 src/libvirt.c |   16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/libvirt.c b/src/libvirt.c
index 405c13f..c48bc7b 100644
--- a/src/libvirt.c
+++ b/src/libvirt.c
@@ -4057,14 +4057,14 @@ error:
  *
  * Here is a sample code snippet:
  *
- * if ((virDomainGetMemoryParameters(dom, NULL, &nparams, 0) == 0) &&
- *     (nparams != 0)) {
- *     if ((params = malloc(sizeof(*params) * nparams)) == NULL)
- *         goto error;
- *     memset(params, 0, sizeof(*params) * nparams);
- *     if (virDomainGetMemoryParameters(dom, params, &nparams, 0))
- *         goto error;
- * }
+ *   if ((virDomainGetMemoryParameters(dom, NULL, &nparams, 0) == 0) &&
+ *       (nparams != 0)) {
+ *       if ((params = malloc(sizeof(*params) * nparams)) == NULL)
+ *           goto error;
+ *       memset(params, 0, sizeof(*params) * nparams);
+ *       if (virDomainGetMemoryParameters(dom, params, &nparams, 0))
+ *           goto error;
+ *   }
  *
  * This function may require privileged access to the hypervisor. This function
  * expects the caller to allocate the @params.
-- 
1.7.9.5




More information about the libvir-list mailing list