summaryrefslogtreecommitdiff
path: root/camlibs/jl2005c
diff options
context:
space:
mode:
authorMarcus Meissner <marcus@jet.franken.de>2014-04-11 19:49:37 +0000
committerMarcus Meissner <marcus@jet.franken.de>2014-04-11 19:49:37 +0000
commitd9f062d842a66fc8c0b1b8f57c380c362b60ef46 (patch)
tree9ae72e92a9b00b8f6882868be6e4359a9575ef2e /camlibs/jl2005c
parentf097b19028f2ea6af5163a55b5a3d8f8a493ba67 (diff)
downloadlibgphoto2-d9f062d842a66fc8c0b1b8f57c380c362b60ef46.tar.gz
From: "Daniel P. Berrange" <dan@berrange.com>
The jl2005bcd_decompress assigns a 'uint16_t *' variable from a 'char *'. Since the two types are different sizes it is safer to add an explicit cast to make it clear what the intended type promotion behaviour is. git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@14890 67ed7778-7388-44ab-90cf-0a291f65f57c
Diffstat (limited to 'camlibs/jl2005c')
-rw-r--r--camlibs/jl2005c/jl2005bcd_decompress.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/camlibs/jl2005c/jl2005bcd_decompress.c b/camlibs/jl2005c/jl2005bcd_decompress.c
index 2524738c0..ea847ac3f 100644
--- a/camlibs/jl2005c/jl2005bcd_decompress.c
+++ b/camlibs/jl2005c/jl2005bcd_decompress.c
@@ -124,7 +124,7 @@ jl2005bcd_decompress (unsigned char *output, unsigned char *input,
return GP_ERROR_NOT_SUPPORTED;
} else {
out = malloc(thumbnail_width * thumbnail_height * 3);
- thumb = input + 16;
+ thumb = (uint16_t *)(input + 16);
for (i = 0; i < thumbnail_width * thumbnail_height;
i++) {
thumb[i] = be16toh(thumb[i]);