Skip to content

Commit c693abf

Browse files
committed
signals: ignore signal pipe like cpython does
1 parent 15d558e commit c693abf

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/jit.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,6 +379,16 @@ static int main(int argc, char** argv) {
379379
setvbuf(stderr, (char*)NULL, _IONBF, BUFSIZ);
380380
}
381381

382+
#ifdef SIGPIPE
383+
PyOS_setsig(SIGPIPE, SIG_IGN);
384+
#endif
385+
#ifdef SIGXFZ
386+
PyOS_setsig(SIGXFZ, SIG_IGN);
387+
#endif
388+
#ifdef SIGXFSZ
389+
PyOS_setsig(SIGXFSZ, SIG_IGN);
390+
#endif
391+
382392
if (ASSEMBLY_LOGGING) {
383393
assembler::disassemblyInitialize();
384394
}

0 commit comments

Comments
 (0)