aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/common/enum-flags.h3
2 files changed, 7 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 49ffd4a..1e0e50e 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
+
+ * common/enum-flags.h (enum_flags::enum_flags): Initialize
+ m_enum_value to 0 in default constructor.
+
2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
* rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
diff --git a/gdb/common/enum-flags.h b/gdb/common/enum-flags.h
index 5b8c3ebc..e63c8a4 100644
--- a/gdb/common/enum-flags.h
+++ b/gdb/common/enum-flags.h
@@ -115,8 +115,9 @@ private:
}
public:
- /* Allow default construction, just like raw enums. */
+ /* Allow default construction. */
enum_flags ()
+ : m_enum_value ((enum_type) 0)
{}
enum_flags (const enum_flags &other)