Page 1 of 1

Convert Stack Overflow issue while using ASP

Posted: 2006-11-10T12:20:29-07:00
by bmmerrell
I'm running Windows Server 2003 Standard service pack 1
with IIS version 6
and ImageMagick 6.3.0

i'm running some code in an asp page:

Code: Select all

<%
dim filePath1, filePath2
filePath1 = "d:\blah\file1.jpg"
filePath2 = "d:\blah\file1_thumb.jpg"

dim FSO
set FSO = server.createObject("scripting.filesystemobject")
	
if FSO.fileExists(filePath1) then
	dim imageFile
	set imageFile = FSO.getFile(filePath1)
		
	dim IMG
	set IMG = server.createObject("ImageMagickObject.MagickImage.1")
	IMG.convert filePath1, "-thumbnail", "75x75", filePath2
	set IMG = nothing
		
	imageFile.delete true
end if
	
set FSO = nothing
%>
...which works beautifully for about 10 runs or so and then quits working after which I begin to receive the following error message:

Code: Select all

ImageMagickObject.MagickImage.1 error '80041771' 

convert: 0xC00000FD: stack overflow 

/test.asp, line 12
At this point, IIS begins to hang and needs to be restarted. The stack overflow error continues to persist until the server is rebooted.

When i execute this code's equivalent with wscript, I seem to be able to run it infinitely without incident.

If anyone has seen this behavior or could suggest a fix, i would be truly grateful. Thanks!

Posted: 2006-11-17T07:39:46-07:00
by bmmerrell
I think I may have found the problem. I have two drives on my server.

The C drive holds the OS as well as all of the installed program files (including the Imagemagick dlls). The D drive is the larger hard drive and it holds all of the IIS systems I have running.

My original system was held on the D drive, but my tests that involved the C drive haven't failed. So I've moved the entire system over, and it seems to be working great.