aboutsummaryrefslogtreecommitdiff
path: root/sim/m32c/gdb-if.c
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-05-29 12:03:27 -0400
committerMike Frysinger <vapier@gentoo.org>2021-05-29 12:03:27 -0400
commit80e61ea097e7a5c272e2d4f6f15a72a226779569 (patch)
tree24d2573a94f2c5b68d41a65189357c5744fcc7c1 /sim/m32c/gdb-if.c
parent5c9e84c2d8208444772cae8130a23aa27407f32c (diff)
downloadgdb-80e61ea097e7a5c272e2d4f6f15a72a226779569.zip
gdb-80e61ea097e7a5c272e2d4f6f15a72a226779569.tar.gz
gdb-80e61ea097e7a5c272e2d4f6f15a72a226779569.tar.bz2
sim: m32c: rename open symbol to avoid collisions
If the header files define open(), make sure our local open var doesn't shadow it.
Diffstat (limited to 'sim/m32c/gdb-if.c')
-rw-r--r--sim/m32c/gdb-if.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sim/m32c/gdb-if.c b/sim/m32c/gdb-if.c
index b00d878..b154fe6 100644
--- a/sim/m32c/gdb-if.c
+++ b/sim/m32c/gdb-if.c
@@ -58,7 +58,7 @@ static struct sim_state the_minisim = {
"This is the sole m32c minisim instance. See libsim.a's global variables."
};
-static int open;
+static int is_open;
SIM_DESC
sim_open (SIM_OPEN_KIND kind,
@@ -66,7 +66,7 @@ sim_open (SIM_OPEN_KIND kind,
struct bfd *abfd, char * const *argv)
{
setbuf (stdout, 0);
- if (open)
+ if (is_open)
fprintf (stderr, "m32c minisim: re-opened sim\n");
/* The 'run' interface doesn't use this function, so we don't care
@@ -88,7 +88,7 @@ sim_open (SIM_OPEN_KIND kind,
init_mem ();
init_regs ();
- open = 1;
+ is_open = 1;
return &the_minisim;
}
@@ -107,7 +107,7 @@ sim_close (SIM_DESC sd, int quitting)
/* Not much to do. At least free up our memory. */
init_mem ();
- open = 0;
+ is_open = 0;
}
static bfd *