This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH v2 2/4] gdbserver: avoid empty structs
- From: Mircea Gherzan <mircea dot gherzan at intel dot com>
- To: tromey at redhat dot com, palves at redhat dot com, jan dot kratochvil at redhat dot com
- Cc: gdb-patches at sourceware dot org, Mircea Gherzan <mircea dot gherzan at intel dot com>
- Date: Mon, 1 Jul 2013 19:24:54 +0200
- Subject: [PATCH v2 2/4] gdbserver: avoid empty structs
- References: <1372699497-20043-1-git-send-email-mircea dot gherzan at intel dot com>
2013-06-25 Mircea Gherzan <mircea.gherzan@intel.com>
gdbserver/
* notif.h (notif_event): Add a dummy member to avoid compiler
errors.
Signed-off-by: Mircea Gherzan <mircea.gherzan@intel.com>
---
gdb/gdbserver/notif.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/gdb/gdbserver/notif.h b/gdb/gdbserver/notif.h
index 608b763..c714e7b 100644
--- a/gdb/gdbserver/notif.h
+++ b/gdb/gdbserver/notif.h
@@ -27,6 +27,8 @@
typedef struct notif_event
{
+ /* C requires that a struct or union has at least one member. */
+ char dummy;
} *notif_event_p;
DECLARE_QUEUE_P (notif_event_p);
--
1.7.12.4