aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sim/ppc/ChangeLog6
-rw-r--r--sim/ppc/main.c2
-rw-r--r--sim/ppc/sim_calls.c10
3 files changed, 16 insertions, 2 deletions
diff --git a/sim/ppc/ChangeLog b/sim/ppc/ChangeLog
index b41d202..7a23d68 100644
--- a/sim/ppc/ChangeLog
+++ b/sim/ppc/ChangeLog
@@ -1,3 +1,9 @@
+2021-06-29 Mike Frysinger <vapier@gentoo.org>
+
+ * main.c (sim_io_error): Add comment
+ * sim_calls.c (sim_io_error): Likewise. Change "" to " ".
+ (error): Likewise.
+
2021-06-20 Mike Frysinger <vapier@gentoo.org>
* Makefile.in (INLINE_CFLAGS): Change to $(SIM_INLINE).
diff --git a/sim/ppc/main.c b/sim/ppc/main.c
index 0c1a070..2d4d7e4 100644
--- a/sim/ppc/main.c
+++ b/sim/ppc/main.c
@@ -214,6 +214,8 @@ sim_io_flush_stdoutput(void)
}
}
+/* Glue to use sim-fpu module. */
+
void
sim_io_error (SIM_DESC sd, const char *msg, ...)
{
diff --git a/sim/ppc/sim_calls.c b/sim/ppc/sim_calls.c
index 14d4d65..ee9d123 100644
--- a/sim/ppc/sim_calls.c
+++ b/sim/ppc/sim_calls.c
@@ -372,6 +372,8 @@ sim_io_flush_stdoutput(void)
}
}
+/* Glue to use sim-fpu module. */
+
void
sim_io_error (SIM_DESC sd, const char *fmt, ...)
{
@@ -379,7 +381,9 @@ sim_io_error (SIM_DESC sd, const char *fmt, ...)
va_start(ap, fmt);
callbacks->evprintf_filtered (callbacks, fmt, ap);
va_end(ap);
- callbacks->error (callbacks, "");
+ /* Printing a space here avoids empty printf compiler warnings. Not ideal,
+ but we want error's side-effect where it halts processing. */
+ callbacks->error (callbacks, " ");
}
/****/
@@ -391,7 +395,9 @@ error (const char *msg, ...)
va_start(ap, msg);
callbacks->evprintf_filtered (callbacks, msg, ap);
va_end(ap);
- callbacks->error (callbacks, "");
+ /* Printing a space here avoids empty printf compiler warnings. Not ideal,
+ but we want error's side-effect where it halts processing. */
+ callbacks->error (callbacks, " ");
}
void *