Bugfix getimagesize

Remove a bug in imagepath for getimagesize.