summaryrefslogtreecommitdiff
path: root/camlibs/spca50x
diff options
context:
space:
mode:
authorMarcus Meissner <marcus@jet.franken.de>2020-09-07 16:38:14 +0200
committerMarcus Meissner <marcus@jet.franken.de>2020-09-07 16:38:51 +0200
commit82e7d69df93d385cc2c507b4e62312c78976e934 (patch)
treef36ded7a98e28133dfad41ca4ed6cb03d5c18ddb /camlibs/spca50x
parent478d8c74abb48f0b4bfb7da7c230b4f2d6bdbbf9 (diff)
downloadlibgphoto2-82e7d69df93d385cc2c507b4e62312c78976e934.tar.gz
fixed a condition to be correct (AFL)
Diffstat (limited to 'camlibs/spca50x')
-rw-r--r--camlibs/spca50x/spca50x.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/camlibs/spca50x/spca50x.c b/camlibs/spca50x/spca50x.c
index 54072807f..3255ecf87 100644
--- a/camlibs/spca50x/spca50x.c
+++ b/camlibs/spca50x/spca50x.c
@@ -217,7 +217,7 @@ create_jpeg_from_data (uint8_t * dst, uint8_t * src, unsigned int qIndex, int w,
SPCA50X_JPG_DEFAULT_HEADER_PART1_LENGTH);
/* modify quantization table */
- if (qIndex > sizeof(SPCA50xQTable)/sizeof(SPCA50xQTable[0])/2) {
+ if (qIndex >= sizeof(SPCA50xQTable)/sizeof(SPCA50xQTable[0])/2) {
gp_log(GP_LOG_ERROR,"create_jpeg_from_data","qIndex %d too large", qIndex);
return GP_ERROR;
}