Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions hotspot/src/share/vm/gc_implementation/g1/g1GCPhaseTimes.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2025, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -34,13 +34,14 @@
class LineBuffer: public StackObj {

private:
static const int BUFFER_LEN = 1024;
static const int BUFFER_LEN = 1024*3;
static const int INDENT_CHARS = 3;
char _buffer[BUFFER_LEN];
int _indent_level;
int _cur;

void vappend(const char* format, va_list ap) ATTRIBUTE_PRINTF(2, 0) {
guarantee(_cur < BUFFER_LEN, "buffer overflow in LineBuffer");
int res = os::vsnprintf(&_buffer[_cur], BUFFER_LEN - _cur, format, ap);
if (res > BUFFER_LEN) {
DEBUG_ONLY(warning("buffer too small in LineBuffer");)
Expand Down