}
for (i = 0; i < MAX_ATOMS_IN_BOX && DBGetSize(db) > 0; i++) {
- (void) ParseAtom(image, db, ctx, exception);
+ if (ParseAtom(image, db, ctx, exception) == MagickFalse)
+ return MagickFalse;
}
return MagickTrue;
i;
for (i = 0; i < MAX_ATOMS_IN_BOX && DBGetSize(db) > 0; i++) {
- (void) ParseAtom(image, db, ctx, exception);
+ if (ParseAtom(image, db, ctx, exception) == MagickFalse)
+ break;
}
return MagickTrue;
/*
item indicies starts from 1
*/
- if (id >= (ssize_t) ctx->idsCount) {
+ if (id > (ssize_t) ctx->idsCount) {
ThrowAndReturn("item id is incorrect");
}