From a0f078d9a429267e1aab705877f7fbbe014353bc Mon Sep 17 00:00:00 2001 From: Davis King Date: Tue, 30 Sep 2014 21:59:08 -0400 Subject: [PATCH] Minor changes to avoid errors and warnings in visual studio. --- dlib/external/libjpeg/jchuff.cpp | 4 ++-- dlib/external/libjpeg/jcphuff.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dlib/external/libjpeg/jchuff.cpp b/dlib/external/libjpeg/jchuff.cpp index 6ebea13b0..bafb8d0d0 100644 --- a/dlib/external/libjpeg/jchuff.cpp +++ b/dlib/external/libjpeg/jchuff.cpp @@ -297,7 +297,7 @@ dump_buffer (working_state * state) * between calls, so 24 bits are sufficient. */ -INLINE +inline LOCAL(int) emit_bits (working_state * state, unsigned int code, int size) /* Emit some bits; return TRUE if successful, FALSE if must suspend */ @@ -827,7 +827,7 @@ jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]) for (i = 1; i <= MAX_CLEN; i++) { for (j = 0; j <= 255; j++) { if (codesize[j] == i) { - htbl->huffval[p] = (unsigned short) j; + htbl->huffval[p] = (unsigned char) j; p++; } } diff --git a/dlib/external/libjpeg/jcphuff.cpp b/dlib/external/libjpeg/jcphuff.cpp index 16f67f7da..17805a528 100644 --- a/dlib/external/libjpeg/jcphuff.cpp +++ b/dlib/external/libjpeg/jcphuff.cpp @@ -223,7 +223,7 @@ dump_buffer (phuff_entropy_ptr entropy) * between calls, so 24 bits are sufficient. */ -INLINE +inline LOCAL(void) emit_bits (phuff_entropy_ptr entropy, unsigned int code, int size) /* Emit some bits, unless we are in gather mode */ @@ -276,7 +276,7 @@ flush_bits (phuff_entropy_ptr entropy) * Emit (or just count) a Huffman symbol. */ -INLINE +inline LOCAL(void) emit_symbol (phuff_entropy_ptr entropy, int tbl_no, int symbol) {