mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-25 05:45:11 +02:00
8076475: Misuses of strncpy/strncat
Various small fixes around strncpy and strncat Reviewed-by: dsamersoff, coleenp
This commit is contained in:
parent
137a04308f
commit
c034b74806
12 changed files with 56 additions and 52 deletions
|
@ -300,6 +300,7 @@ address decode_env::handle_event(const char* event, address arg) {
|
|||
strlen((const char*)arg) > sizeof(buffer) - 1) {
|
||||
// Only print this when the mach changes
|
||||
strncpy(buffer, (const char*)arg, sizeof(buffer) - 1);
|
||||
buffer[sizeof(buffer) - 1] = '\0';
|
||||
output()->print_cr("[Disassembling for mach='%s']", arg);
|
||||
}
|
||||
} else if (match(event, "format bytes-per-line")) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue