[FFmpeg-devel] [PATCH] examples/muxing: improve error messages.
nicolas.george at normalesup.org
Wed Jan 2 17:47:32 CET 2013
Le tridi 13 nivôse, an CCXXI, Stefano Sabatini a écrit :
> BTW we should avoid to exit() from functions, return an error code
> instead and do proper cleanup in the calling function (at that point
> error reporting could be factorized).
The purpose of the examples is to illustrate the API, not to educate with
good coding practices, and direct exit() is completely acceptable in quite a
lot of situations.
Therefore, eliminating exit() is not a goal in itself: if it makes the code
simpler and/or more readable, 100% ok. If it does not make the code less
readable, why not, but there are more urgent issues.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 198 bytes
Desc: Digital signature
More information about the ffmpeg-devel