Patchwork [11/24] qapi/qmp-registry.c: include headers it needs

login
register
mail settings
Submitter Eduardo Habkost
Date Nov. 9, 2012, 2:56 p.m.
Message ID <1352473012-20500-12-git-send-email-ehabkost@redhat.com>
Download mbox | patch
Permalink /patch/198090/
State New
Headers show

Comments

Eduardo Habkost - Nov. 9, 2012, 2:56 p.m.
Include:
- <glib.h> for g_malloc0()
- <string.h> for strcmp()

Some of those headers were probably being included by accident because
some other headers were including qemu-common.h, but those headers
should eventually stop including qemu-common.h.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
 qapi/qmp-registry.c | 2 ++
 1 file changed, 2 insertions(+)
Andreas Färber - Nov. 14, 2012, 3:47 p.m.
Am 09.11.2012 15:56, schrieb Eduardo Habkost:
> Include:
> - <glib.h> for g_malloc0()
> - <string.h> for strcmp()
> 
> Some of those headers were probably being included by accident because
> some other headers were including qemu-common.h, but those headers
> should eventually stop including qemu-common.h.
> 
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>

Acked-by: Andreas Färber <afaerber@suse.de>

Andreas

Patch

diff --git a/qapi/qmp-registry.c b/qapi/qmp-registry.c
index 5414613..c2c31b4 100644
--- a/qapi/qmp-registry.c
+++ b/qapi/qmp-registry.c
@@ -12,6 +12,8 @@ 
  *
  */
 
+#include <glib.h>
+#include <string.h>
 #include "qapi/qmp-core.h"
 
 static QTAILQ_HEAD(QmpCommandList, QmpCommand) qmp_commands =