@@ -207,7 +207,9 @@ class ExceptionsEventLog : public ExtendedStringEventLog {
207
207
ExceptionsEventLog (const char * name, const char * short_name, int count = LogEventsBufferEntries)
208
208
: ExtendedStringEventLog(name, short_name, count) {}
209
209
210
- void log (Thread* thread, Handle h_exception, const char * message, const char * file, int line);
210
+ // Message length limit of zero means no limit.
211
+ void log (Thread* thread, Handle h_exception, const char * message,
212
+ const char * file, int line, int message_length_limit = 0 );
211
213
};
212
214
213
215
@@ -275,7 +277,7 @@ class Events : AllStatic {
275
277
276
278
// Log exception related message
277
279
static void log_exception (Thread* thread, const char * format, ...) ATTRIBUTE_PRINTF(2 , 3 );
278
- static void log_exception (Thread* thread, Handle h_exception, const char * message, const char * file, int line);
280
+ static void log_exception (Thread* thread, Handle h_exception, const char * message, const char * file, int line, int message_length_limit = 0 );
279
281
280
282
static void log_redefinition (Thread* thread, const char * format, ...) ATTRIBUTE_PRINTF(2 , 3 );
281
283
@@ -345,9 +347,11 @@ inline void Events::log_exception(Thread* thread, const char* format, ...) {
345
347
}
346
348
}
347
349
348
- inline void Events::log_exception (Thread* thread, Handle h_exception, const char * message, const char * file, int line) {
350
+ inline void Events::log_exception (Thread* thread, Handle h_exception,
351
+ const char * message, const char * file,
352
+ int line, int message_length_limit) {
349
353
if (LogEvents && _exceptions != nullptr ) {
350
- _exceptions->log (thread, h_exception, message, file, line);
354
+ _exceptions->log (thread, h_exception, message, file, line, message_length_limit );
351
355
}
352
356
}
353
357
0 commit comments