Add explicit cast from ulong to int to remove compiler error

This commit is contained in:
Allen Garvey 2017-02-09 20:54:28 -05:00
parent 72bd2ed6ee
commit 852d3cf933
1 changed files with 1 additions and 1 deletions

2
jpeg.d
View File

@ -2591,7 +2591,7 @@ private:
cb.block_num_y = block_num_y;
cb.block_len_x = block_len_x;
cb.block_len_y = block_len_y;
cb.block_size = (block_len_x * block_len_y) * jpgd_block_t.sizeof;
cb.block_size = cast(int)((block_len_x * block_len_y) * jpgd_block_t.sizeof);
cb.pData = cast(ubyte*)alloc(cb.block_size * block_num_x * block_num_y, true);
return cb;
}