clang complained that we may end up jumping
to the cleanup code without initializing data
in the jpeg code. Always initialize data to
NULL to prevent that eventuality.
struct jpeg_decompress_struct info;
struct error_handler_data jerr;
guint width, height, stride;
- unsigned char *data;
+ unsigned char *data = NULL;
unsigned char *row[1];
GBytes *bytes;
GdkTexture *texture;
if (sigsetjmp (jerr.setjmp_buffer, 1))
{
+ g_free (data);
jpeg_destroy_decompress (&info);
return NULL;
}
struct jpeg_compress_struct info;
struct error_handler_data jerr;
struct jpeg_error_mgr err;
- guchar *data;
+ guchar *data = NULL;
gulong size = 0;
guchar *input = NULL;
GdkMemoryTexture *memtex = NULL;