--- a/hotspot/src/os/posix/vm/os_posix.cpp Fri May 09 08:34:22 2014 -0700
+++ b/hotspot/src/os/posix/vm/os_posix.cpp Fri May 09 16:50:54 2014 -0400
@@ -36,6 +36,8 @@
#include <pthread.h>
#include <signal.h>
+PRAGMA_FORMAT_MUTE_WARNINGS_FOR_GCC
+
// Todo: provide a os::get_max_process_id() or similar. Number of processes
// may have been configured, can be read more accurately from proc fs etc.
#ifndef MAX_PID
@@ -192,10 +194,10 @@
st->print("uname:");
struct utsname name;
uname(&name);
- st->print(name.sysname); st->print(" ");
- st->print(name.release); st->print(" ");
- st->print(name.version); st->print(" ");
- st->print(name.machine);
+ st->print("%s ", name.sysname);
+ st->print("%s ", name.release);
+ st->print("%s ", name.version);
+ st->print("%s", name.machine);
st->cr();
}
@@ -682,7 +684,7 @@
void os::Posix::print_signal_set_short(outputStream* st, const sigset_t* set) {
char buf[NUM_IMPORTANT_SIGS + 1];
os::Posix::describe_signal_set_short(set, buf, sizeof(buf));
- st->print(buf);
+ st->print("%s", buf);
}
// Writes one-line description of a combination of sigaction.sa_flags into a user
@@ -742,7 +744,7 @@
void os::Posix::print_sa_flags(outputStream* st, int flags) {
char buffer[0x100];
os::Posix::describe_sa_flags(flags, buffer, sizeof(buffer));
- st->print(buffer);
+ st->print("%s", buffer);
}
// Helper function for os::Posix::print_siginfo_...():