FIX 5284: Implemented check in GD that estimates the memory needed to load the image and rejects large images. Created lock files that remain if a large image crashes GD.
Fixed inconsistent method name
Fixed typo.
for($i=0; $i<3; $i++) echo "I shall test my code";
Updated with changes from the discussion of the last commit.