[vlc-devel] [PATCH] jpeg: add a comment and an assertion to explain error handling
Maxim Bublis
b at codemonkey.ru
Tue Jan 28 16:48:48 CET 2014
> p_jpeg.err = jpeg_std_error(&p_sys->err);
> + /* XXX: we rely on p_sys->err being the first member of sys_t struct,
> + * so its address is the same than p_sys and we can retrieve p_sys
> + * address in libjpeg error handlers */
> + assert((decoder_sys_t*)p_sys->p_jpeg.err == p_sys);
> p_sys->err.error_exit = user_error_exit;
> p_sys->err.output_message = user_error_message;
>
I guess it should be p_sys->err after recent changes.
--
Maxim Bublis
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20140128/c8162c06/attachment.html>
More information about the vlc-devel
mailing list