Commit e6ac2ca3 authored by KeySecure's avatar KeySecure

make Xcode 7.2 happy.

parent 70cb17bf
...@@ -265,9 +265,9 @@ typedef struct { ...@@ -265,9 +265,9 @@ typedef struct {
INT32 volume; INT32 volume;
/* The number of nonzero histogram cells within this box */ /* The number of nonzero histogram cells within this box */
long colorcount; long colorcount;
} box; } _box;
typedef box * boxptr; typedef _box * boxptr;
LOCAL(boxptr) LOCAL(boxptr)
...@@ -546,7 +546,7 @@ select_colors (j_decompress_ptr cinfo, int desired_colors) ...@@ -546,7 +546,7 @@ select_colors (j_decompress_ptr cinfo, int desired_colors)
/* Allocate workspace for box list */ /* Allocate workspace for box list */
boxlist = (boxptr) (*cinfo->mem->alloc_small) boxlist = (boxptr) (*cinfo->mem->alloc_small)
((j_common_ptr) cinfo, JPOOL_IMAGE, desired_colors * SIZEOF(box)); ((j_common_ptr) cinfo, JPOOL_IMAGE, desired_colors * SIZEOF(_box));
/* Initialize one box containing whole space */ /* Initialize one box containing whole space */
numboxes = 1; numboxes = 1;
boxlist[0].c0min = 0; boxlist[0].c0min = 0;
......
...@@ -27,7 +27,7 @@ local int gz_load(state, buf, len, have) ...@@ -27,7 +27,7 @@ local int gz_load(state, buf, len, have)
*have = 0; *have = 0;
do { do {
ret = read(state->fd, buf + *have, len - *have); ret = (int) read(state->fd, buf + *have, len - *have);
if (ret <= 0) if (ret <= 0)
break; break;
*have += ret; *have += ret;
......
...@@ -81,7 +81,7 @@ local int gz_comp(state, flush) ...@@ -81,7 +81,7 @@ local int gz_comp(state, flush)
/* write directly if requested */ /* write directly if requested */
if (state->direct) { if (state->direct) {
got = write(state->fd, strm->next_in, strm->avail_in); got = (int) write(state->fd, strm->next_in, strm->avail_in);
if (got < 0 || (unsigned)got != strm->avail_in) { if (got < 0 || (unsigned)got != strm->avail_in) {
gz_error(state, Z_ERRNO, zstrerror()); gz_error(state, Z_ERRNO, zstrerror());
return -1; return -1;
...@@ -98,7 +98,7 @@ local int gz_comp(state, flush) ...@@ -98,7 +98,7 @@ local int gz_comp(state, flush)
if (strm->avail_out == 0 || (flush != Z_NO_FLUSH && if (strm->avail_out == 0 || (flush != Z_NO_FLUSH &&
(flush != Z_FINISH || ret == Z_STREAM_END))) { (flush != Z_FINISH || ret == Z_STREAM_END))) {
have = (unsigned)(strm->next_out - state->x.next); have = (unsigned)(strm->next_out - state->x.next);
if (have && ((got = write(state->fd, state->x.next, have)) < 0 || if (have && ((got = (int) write(state->fd, state->x.next, have)) < 0 ||
(unsigned)got != have)) { (unsigned)got != have)) {
gz_error(state, Z_ERRNO, zstrerror()); gz_error(state, Z_ERRNO, zstrerror());
return -1; return -1;
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
*/ */
/* Includes */ /* Includes */
#include <precomp.hpp> #include "precomp.hpp"
#include <opencv2/core.hpp> #include <opencv2/core.hpp>
#include <stdlib.h> #include <stdlib.h>
#include <stdio.h> #include <stdio.h>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment