MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / sigterm_handler

Function sigterm_handler

fftools/ffmpeg.c:147–160  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

145static int64_t copy_ts_first_pts = AV_NOPTS_VALUE;
146
147static void
148sigterm_handler(int sig)
149{
150 int ret;
151 received_sigterm = sig;
152 received_nb_signals++;
153 term_exit_sigsafe();
154 if(received_nb_signals > 3) {
155 ret = write(2/*STDERR_FILENO*/, "Received > 3 system signals, hard exiting\n",
156 strlen("Received > 3 system signals, hard exiting\n"));
157 if (ret < 0) { /* Do nothing */ };
158 exit(123);
159 }
160}
161
162#if HAVE_SETCONSOLECTRLHANDLER
163static BOOL WINAPI CtrlHandler(DWORD fdwCtrlType)

Callers 1

CtrlHandlerFunction · 0.70

Calls 1

term_exit_sigsafeFunction · 0.85

Tested by

no test coverage detected