summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/libjpeg/jdatadst.c
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2015-01-10 12:50:58 +0100
committer Miodrag Milanovic <mmicko@gmail.com>2015-01-10 12:50:58 +0100
commit0404bdd34cb4779129f372ce735f316379644a84 (patch)
tree4c11357fbfa3b2c7d25172c29d59be54d3f67f1f /3rdparty/libjpeg/jdatadst.c
parentb0640c888bf6b9cb655e72a98e60ba6f9dcd8434 (diff)
Fixes for libjpeg compile (nw)
Diffstat (limited to '3rdparty/libjpeg/jdatadst.c')
-rw-r--r--3rdparty/libjpeg/jdatadst.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/3rdparty/libjpeg/jdatadst.c b/3rdparty/libjpeg/jdatadst.c
index 472d5f32418..a0ccfb20a66 100644
--- a/3rdparty/libjpeg/jdatadst.c
+++ b/3rdparty/libjpeg/jdatadst.c
@@ -128,7 +128,7 @@ empty_mem_output_buffer (j_compress_ptr cinfo)
/* Try to allocate new buffer with double size */
nextsize = dest->bufsize * 2;
- nextbuffer = malloc(nextsize);
+ nextbuffer = (JOCTET*)malloc(nextsize);
if (nextbuffer == NULL)
ERREXIT1(cinfo, JERR_OUT_OF_MEMORY, 10);
@@ -256,7 +256,7 @@ jpeg_mem_dest (j_compress_ptr cinfo,
if (*outbuffer == NULL || *outsize == 0) {
/* Allocate initial buffer */
- dest->newbuffer = *outbuffer = malloc(OUTPUT_BUF_SIZE);
+ dest->newbuffer = *outbuffer = (unsigned char*)malloc(OUTPUT_BUF_SIZE);
if (dest->newbuffer == NULL)
ERREXIT1(cinfo, JERR_OUT_OF_MEMORY, 10);
*outsize = OUTPUT_BUF_SIZE;