diff options
author | Pedro Alves <palves@redhat.com> | 2015-08-21 23:49:37 +0100 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2015-08-21 23:49:37 +0100 |
commit | f8904751117dc8d4d04e5c5286b71b854e6ebba5 (patch) | |
tree | def38f1d522d2bbc5622b50ae976cee9b97868e6 /gdb/gdbserver/tdesc.c | |
parent | 049412e38f9ac04654940173db63a37ebca9bfc3 (diff) | |
download | gdb-f8904751117dc8d4d04e5c5286b71b854e6ebba5.zip gdb-f8904751117dc8d4d04e5c5286b71b854e6ebba5.tar.gz gdb-f8904751117dc8d4d04e5c5286b71b854e6ebba5.tar.bz2 |
C++: Initialize a couple const globals
In C++ mode, we get:
src/gdb/gdbserver/tdesc.c:43:33: error: uninitialized const ‘default_description’ [-fpermissive]
static const struct target_desc default_description;
^
In file included from src/gdb/gdbserver/tdesc.c:19:0:
src/gdb/gdbserver/tdesc.h:26:8: note: ‘const struct target_desc’ has no user-provided default constructor
struct target_desc
^
gdb/ChangeLog:
2015-08-21 Pedro Alves <palves@redhat.com>
* frame.c (null_frame_id): Explicitly zero-initialize.
gdb/gdbserver/ChangeLog:
2015-08-21 Pedro Alves <palves@redhat.com>
* tdesc.c (default_description): Explicitly zero-initialize.
Diffstat (limited to 'gdb/gdbserver/tdesc.c')
-rw-r--r-- | gdb/gdbserver/tdesc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/gdbserver/tdesc.c b/gdb/gdbserver/tdesc.c index 8d008fd..1263efe 100644 --- a/gdb/gdbserver/tdesc.c +++ b/gdb/gdbserver/tdesc.c @@ -40,7 +40,7 @@ init_target_desc (struct target_desc *tdesc) #ifndef IN_PROCESS_AGENT -static const struct target_desc default_description; +static const struct target_desc default_description = { 0 }; void copy_target_description (struct target_desc *dest, |