MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / formatWindowsFfmpegExit

Function formatWindowsFfmpegExit

packages/engine/src/utils/runFfmpeg.ts:30–45  ·  view source on GitHub ↗
(exitCode: number | null)

Source from the content-addressed store, hash-verified

28const DEFAULT_STDERR_TAIL_LINES = 15;
29
30function formatWindowsFfmpegExit(exitCode: number | null): string | undefined {
31 if (process.platform !== "win32" || exitCode === null) return undefined;
32 if (exitCode === 3221225595 || exitCode === -1073741701) {
33 return (
34 "[FFmpeg] Windows could not start ffmpeg.exe (STATUS_INVALID_IMAGE_FORMAT). " +
35 "The binary may be corrupted or the wrong architecture. Reinstall a 64-bit Windows FFmpeg build."
36 );
37 }
38 if (exitCode === 3221225794 || exitCode === -1073741502) {
39 return (
40 "[FFmpeg] Windows failed while initializing ffmpeg.exe. " +
41 "The binary may be corrupted, blocked, or missing runtime DLLs. Reinstall a 64-bit Windows FFmpeg build."
42 );
43 }
44 return undefined;
45}
46
47/**
48 * Build a user-facing error message for a failed ffmpeg invocation.

Callers 1

formatFfmpegErrorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected