Mercurial > hg > dmlib
comparison tools/lib64gfx.c @ 1710:1f0fac3af8e3
Use buf->len instead of tmp.len, as it might not be initialized.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 06 Jun 2018 14:26:49 +0300 |
parents | a0986cfd6f9d |
children | 0a9110b4d036 |
comparison
equal
deleted
inserted
replaced
1709:2b592df78943 | 1710:1f0fac3af8e3 |
---|---|
1270 dmGrowBufCreateFromOffs(&tmp, buf, probeOffs); | 1270 dmGrowBufCreateFromOffs(&tmp, buf, probeOffs); |
1271 if (dmC64ProbeBMP(tmp.data, tmp.len, fmt) == DM_PROBE_SCORE_FALSE) | 1271 if (dmC64ProbeBMP(tmp.data, tmp.len, fmt) == DM_PROBE_SCORE_FALSE) |
1272 return DMERR_NOT_SUPPORTED; | 1272 return DMERR_NOT_SUPPORTED; |
1273 } | 1273 } |
1274 | 1274 |
1275 if (loadOffs >= tmp.len) | 1275 if (loadOffs >= buf->len) |
1276 return DMERR_INVALID_ARGS; | 1276 return DMERR_INVALID_ARGS; |
1277 | 1277 |
1278 if (*fmt == NULL) | 1278 if (*fmt == NULL) |
1279 return DMERR_NOT_SUPPORTED; | 1279 return DMERR_NOT_SUPPORTED; |
1280 | 1280 |