[plt-scheme] a problem about servlet

From: Zhu Chongkai (mathematica at citiz.net)
Date: Sun Dec 5 01:54:14 EST 2004

Hi all,

When writing a servlet in PLT-Scheme, I want to serve some dynamic
content as GIF image. So I write the servlet as:


(send/suspend ...) ;reads in some user inputs

... ;creates a GIF image under web-root/htdocs

(send/finish `(... (img ...) ...)
;produce the final output web page which refers to the GIF

(sleep 30) ; waits for the server to transfer data

(delete-file ...) ; delete the GIF file


The servlet works and the output web page is what I need. But the
GIF file was not deleted even after the 30 seconds waiting time
(and thus many GIFs aaccumulate under web-root/htdocs). Why? And
how to make it work (delete the file)?

Thanks in advance.


Best regards, 
Zhu Chongkai
http://www.tcfb.com/mrmathematica/



Posted on the users mailing list.