1.1 --- a/src/share/vm/compiler/compileBroker.hpp Mon Sep 23 20:26:18 2019 +0200 1.2 +++ b/src/share/vm/compiler/compileBroker.hpp Fri Apr 03 14:14:26 2020 +0100 1.3 @@ -173,7 +173,8 @@ 1.4 // these methods should be called in a thread safe context 1.5 1.6 void set_current_method(const char* method) { 1.7 - strncpy(_current_method, method, (size_t)cmname_buffer_length); 1.8 + strncpy(_current_method, method, (size_t)cmname_buffer_length-1); 1.9 + _current_method[cmname_buffer_length-1] = '\0'; 1.10 if (UsePerfData) _perf_current_method->set_value(method); 1.11 } 1.12