summaryrefslogtreecommitdiff
path: root/src/Fl_JPEG_Image.cxx
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2018-12-30 11:04:10 +0100
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2018-12-30 11:04:10 +0100
commit362f9350868286b066070df7da1f496df08ecd73 (patch)
treed4bf7e564018d835092fff0f311ebcec6740d02d /src/Fl_JPEG_Image.cxx
parent26bb0e5a831be64f21eec41efef73571aebadab5 (diff)
parentde199c327e9b55bd615f7262724da8ecba1999cf (diff)
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'src/Fl_JPEG_Image.cxx')
-rw-r--r--src/Fl_JPEG_Image.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/Fl_JPEG_Image.cxx b/src/Fl_JPEG_Image.cxx
index 384acd2a4..6dcf030b5 100644
--- a/src/Fl_JPEG_Image.cxx
+++ b/src/Fl_JPEG_Image.cxx
@@ -255,9 +255,8 @@ extern "C" {
static void jpeg_mem_src(j_decompress_ptr cinfo, const unsigned char *data)
{
- my_src_ptr src;
- cinfo->src = (struct jpeg_source_mgr *)malloc(sizeof(my_source_mgr));
- src = (my_src_ptr)cinfo->src;
+ my_src_ptr src = (my_source_mgr*)malloc(sizeof(my_source_mgr));
+ cinfo->src = &(src->pub);
src->pub.init_source = init_source;
src->pub.fill_input_buffer = fill_input_buffer;
src->pub.skip_input_data = skip_input_data;