hotspot/src/share/vm/oops/method.cpp
changeset 24424 2658d7834c6e
parent 24351 61b33cc6d3cf
child 24456 8c7933fa5a1f
--- a/hotspot/src/share/vm/oops/method.cpp	Fri May 09 08:34:22 2014 -0700
+++ b/hotspot/src/share/vm/oops/method.cpp	Fri May 09 16:50:54 2014 -0400
@@ -56,6 +56,7 @@
 #include "utilities/quickSort.hpp"
 #include "utilities/xmlstream.hpp"
 
+PRAGMA_FORMAT_MUTE_WARNINGS_FOR_GCC
 
 // Implementation of Method
 
@@ -1425,7 +1426,7 @@
 
   void type_name(const char* name) {
     if (_use_separator) _st->print(", ");
-    _st->print(name);
+    _st->print("%s", name);
     _use_separator = true;
   }
 
@@ -1898,7 +1899,7 @@
 void Method::print_on(outputStream* st) const {
   ResourceMark rm;
   assert(is_method(), "must be method");
-  st->print_cr(internal_name());
+  st->print_cr("%s", internal_name());
   // get the effect of PrintOopAddress, always, for methods:
   st->print_cr(" - this oop:          "INTPTR_FORMAT, (intptr_t)this);
   st->print   (" - method holder:     "); method_holder()->print_value_on(st); st->cr();
@@ -1981,7 +1982,7 @@
 
 void Method::print_value_on(outputStream* st) const {
   assert(is_method(), "must be method");
-  st->print(internal_name());
+  st->print("%s", internal_name());
   print_address_on(st);
   st->print(" ");
   name()->print_value_on(st);