public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH/committed] sim: cris: fix memory setup typos
@ 2021-05-24  3:43 Mike Frysinger
  0 siblings, 0 replies; only message in thread
From: Mike Frysinger @ 2021-05-24  3:43 UTC (permalink / raw)
  To: gdb-patches

The cleanup to use BFD_VMA_FMT also adjusted this line, but used the
incorrect format: while BFD_VMA_FMT needs an explicit "x", PRIx32 does
not, so the spurious "x" here confused the parser and broke execution.
---
 sim/cris/ChangeLog | 4 ++++
 sim/cris/sim-if.c  | 2 +-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/sim/cris/ChangeLog b/sim/cris/ChangeLog
index 1b4a5fe33662..4e7b919a3c50 100644
--- a/sim/cris/ChangeLog
+++ b/sim/cris/ChangeLog
@@ -1,3 +1,7 @@
+2021-05-23  Mike Frysinger  <vapier@gentoo.org>
+
+	* sim-if.c (sim_open): Delete "x" after PRI macros.
+
 2021-05-23  Mike Frysinger  <vapier@gentoo.org>
 
 	* sim-if.c: Include unistd.h.
diff --git a/sim/cris/sim-if.c b/sim/cris/sim-if.c
index cea499d1daa9..6613a93ecc55 100644
--- a/sim/cris/sim-if.c
+++ b/sim/cris/sim-if.c
@@ -879,7 +879,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd,
 
   /* Allocate core managed memory if none specified by user.  */
   if (sim_core_read_buffer (sd, NULL, read_map, &c, startmem, 1) == 0)
-    sim_do_commandf (sd, "memory region 0x%" PRIx32 "x,0x%" PRIu32 "x",
+    sim_do_commandf (sd, "memory region 0x%" PRIx32 ",0x%" PRIu32,
 		     startmem, endmem - startmem);
 
   /* Allocate simulator I/O managed memory if none specified by user.  */
-- 
2.31.1


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-05-24  3:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-24  3:43 [PATCH/committed] sim: cris: fix memory setup typos Mike Frysinger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).