Only set alpha channel if the remove list is valid
diff --git a/MagickCore/vision.c b/MagickCore/vision.c
index aca2dc7..4b03364 100644
--- a/MagickCore/vision.c
+++ b/MagickCore/vision.c
@@ -581,9 +581,11 @@
if (last < 0)
last+=(long) component_image->colors;
}
- component_image->alpha_trait=BlendPixelTrait;
for (step=first > last ? -1 : 1; first != (last+step); first+=step)
+ {
+ component_image->alpha_trait=BlendPixelTrait;
component_image->colormap[first].alpha=TransparentAlpha;
+ }
}
}
(void) SyncImage(component_image,exception);