Wow, that's really weird. There's no "dangerous" stuff between that and the next debug statement:
debug("Entering subroutine: genThumb($myobject,$image_thumb,$mode)",4,__LINE__);
$system_call="\"$::imagemagick/convert\" ";
if ($::thumb_quality)
{
$system_call.="-quality $::thumb_quality ";
}
# Some older ImageMagick installs don't know "resize" so use "scale" instead
# $system_call.="-scale ";
$system_call.="-resize ";
if ($mode)
{
$system_call.="$::pic_resize";
}
else
{
if ($::thumb_width)
{
$system_call.=$::thumb_width;
}
if ($::thumb_width || $::thumb_height)
{
$system_call.="x";
}
if ($::thumb_height)
{
$system_call.=$::thumb_height;
}
}
$system_call.=" \"$myobject\" \"$image_thumb\"";
# Resize into desired quality and dimensions
debug("IMAGEMAGICK: $system_call",2,__LINE__);
It just sets a variable and then debug output's it. If possible, your best bet is to copy debug statements within this block to try to isolate where it's failing...