8000 Reduce number of printed calls. · python/cpython@db97dd2 · GitHub
[go: up one dir, main page]

Skip to content

Commit db97dd2

Browse files
committed
Reduce number of printed calls.
1 parent f3fcea1 commit db97dd2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Modules/faulthandler.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -220,13 +220,13 @@ faulthandler_dump_traceback(int fd, int all_threads,
220220
static void
221221
faulthandler_stack_dump_impl(int fd)
222222
{
223-
#define BACKTRACE_SIZE 128
223+
#define BACKTRACE_SIZE 16
224224
#define TRACEBACK_ENTRY_MAX_SIZE 256
225225
void *callstack[BACKTRACE_SIZE];
226226
int frames = backtrace(callstack, BACKTRACE_SIZE);
227227
char **strings = backtrace_symbols(callstack, BACKTRACE_SIZE);
228228
if (strings == NULL) {
229-
PUTS(fd, " <failed to get stack trace>");
229+
PUTS(fd, " <failed to get stack trace>\n");
230230
}
231231
else {
232232
for (int i = 0; i < frames; ++i) {
@@ -251,7 +251,7 @@ faulthandler_stack_dump_impl(int fd)
251251
}
252252

253253
if (frames == BACKTRACE_SIZE) {
254-
PUTS(fd, " <truncated rest of calls>");
254+
PUTS(fd, " <truncated rest of calls>\n");
255255
}
256256
}
257257
#undef BACKTRACE_SIZE

0 commit comments

Comments
 (0)