Download & Extend

imagecolorsforindex - color index out of range, watermark.inc

Project:ImageCache Actions
Version:6.x-1.8
Component:Canvas Actions Module
Category:bug report
Priority:normal
Assigned:Unassigned
Status:needs review

Issue Summary

Hello, guys! I'm using canvas imagecache action and I get this error for some gifs

<?php
warning
: imagecolorsforindex() [function.imagecolorsforindex]: Color index 65 out of range in imagecache_actions/watermark.inc on line 50.
?>

I assume all needed is some kind of check for color index before invoking imagecolorsforindex()
could someone help me with that?
I have checked php.net and found this comment

adspeed.com 23-Aug-2005 11:05
To correct m4551 at abasoft dot it example:
ImageTrueColorToPalette($im,1,$t);
might give less colors than $t, so the for loop should call "$i

image uploaded in attachments
Thanks in advance!

Comments

#1

patch attached

AttachmentSize
imagecache-actions-watermark.patch 840 bytes

#2

Status:active» needs review
nobody click here