Skip to content

Subprocess exits without converting or throwing error #6

@henry701

Description

@henry701

Hello, first of all thanks for coding this wrapper. It's very well thought out.

I'm having an issue while using the Engine's Convert method where no event handlers are called, no exceptions are thrown, and the conversion is not carried out by the Engine.

Looking at the code for Engine.cs, I ran into this:

if((this.FFmpegProcess.ExitCode != 0 && this.FFmpegProcess.ExitCode != 1) || caughtException != null)
{
    throw new Exception(
       this.FFmpegProcess.ExitCode + ": " + receivedMessagesLog[1] + receivedMessagesLog[0],
       caughtException);
}

Why is the Engine checking for an ExitCode different than 1 for throwing the exception? I presume the child FFmpeg process is exiting with exit code 1 in my case. I'm using a custom command, but it also happens if I refer to a non-existing file while using the library normally (Convert method).

I can detect there is an error of this kind by checking for the absense of the output file, however I would have to guess or reproduce the command manually on the command line to see what the error returned by FFMpeg was.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions