aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2016-01-04 22:32:49 -0500
committerMike Frysinger <vapier@gentoo.org>2016-01-04 23:01:14 -0500
commit44ddb0c66aa268f0027665da61273e78c9d748ae (patch)
treeb975ac9d376251f9f4473950bb08906da68e0d57
parentbc273e17510c7680bcffee75858d374aa93f7e4b (diff)
downloadgdb-44ddb0c66aa268f0027665da61273e78c9d748ae.zip
gdb-44ddb0c66aa268f0027665da61273e78c9d748ae.tar.gz
gdb-44ddb0c66aa268f0027665da61273e78c9d748ae.tar.bz2
sim: use STATE_MAGIC helper
-rw-r--r--sim/common/ChangeLog4
-rw-r--r--sim/common/sim-utils.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/sim/common/ChangeLog b/sim/common/ChangeLog
index f8cdbf4..8ad6a41 100644
--- a/sim/common/ChangeLog
+++ b/sim/common/ChangeLog
@@ -1,5 +1,9 @@
2016-01-04 Mike Frysinger <vapier@gentoo.org>
+ * sim-utils.c (sim_state_free): Change to STATE_MAGIC.
+
+2016-01-04 Mike Frysinger <vapier@gentoo.org>
+
* cgen-scache.c (MAX): Delete.
(scache_init): Change MAX to max.
* cgen-trace.c (min): Delete.
diff --git a/sim/common/sim-utils.c b/sim/common/sim-utils.c
index d2b5f7c..d11d3b4 100644
--- a/sim/common/sim-utils.c
+++ b/sim/common/sim-utils.c
@@ -101,7 +101,7 @@ sim_state_alloc (SIM_OPEN_KIND kind,
void
sim_state_free (SIM_DESC sd)
{
- ASSERT (sd->base.magic == SIM_MAGIC_NUMBER);
+ ASSERT (STATE_MAGIC (sd) == SIM_MAGIC_NUMBER);
#ifdef SIM_STATE_FREE
SIM_STATE_FREE (sd);