CGI with IIS question (a way to terminate the CGI output but not the CGI)

CGI with IIS question (a way to terminate the CGI output but not the CGI)

Post by Yevgeniy Gelfa » Thu, 14 Mar 2002 02:53:10



I need to have a way to indicate to the IIS that I am finished with
all the output. Basically I want to start a new process with a system
call but have the CGI terminate. But it appears that unless the second
process terminates, the CGI will never finish.

so I need either:

a) A way to tell the CGI: THat's it...I'm done with output...send the
finishing data already

or

b) A way to start another process without IIS thinking it's just a
continuationg of the current CGI and waiting for it to quit (yes, I
tried all the _execl, _spawn with all the OVERLAY, DETACH and other
numerous flags.)

thanx a lot

Yevgeniy Gelfand

 
 
 

CGI with IIS question (a way to terminate the CGI output but not the CGI)

Post by Jim Patterso » Tue, 19 Mar 2002 12:05:45



> I need to have a way to indicate to the IIS that I am finished with
> all the output. Basically I want to start a new process with a system
> call but have the CGI terminate. But it appears that unless the second
> process terminates, the CGI will never finish.

Have you tried just closing the standard output and error streams? That
should work. Once IIS reads and end of file on the CGI output stream, it
should flush it through to the web browser.

You'll need to do this before spawning the subprocess (or at least turn
off inheritance on the handles) as otherwise the streams will still be
open in the subprocess.

--
Jim Patterson
Ottawa, Ont
CANADA

 
 
 

1. IIS cgi with .cgi for perl

 I am trying to set up our NT server to mimic our apache server that runs on
BSD. Having got IIS with NT Server 4.0 I have had no problems getting it to
do almost everything just as the users want it. My two problems are as
follows.

1) I have edited the script map in the registry, but cannot get the server
to serve cgi pages which are perl files ending in .pl at all. I have had no
problems with files called .pl, but the ISAPI perl I installed did it for
me. I have in effect copied the registry entry from that, and it has changed
the error message from the expected 'not supported' message to a 'module not
found' message. I have the script in a directory with all the right
permissions (The perl there works), and wonder what I have missed.

2) This one is not as important, but I am using server side includes, and
wonder how you change the endings which will be parsed? That is can I make
it parse .foo for SSI for instance?

Many thanks in advance,

Rufus

The opinions expressed in this email are not those of the company for which
I work, nor even myself, except where either my opinions or those of the
company happen to coincide with those expressed here.

2. PYSICAL MEMORY PROBLEMS

3. CGI under IIS: .pl work, .cgi don't ???

4. Sound Recorder and Music CD's

5. WebSite 1.1 CGI/Image problem and db CGI app question.

6. MFC Internals: most recent version?

7. IIS FORMs don't terminate CGI stdin

8. how do I install messenger service on a HP320

9. CGI-DOS: A cross platform, cgi script developers tool with debugging features

10. Problems running perl/CGI in cgi-bin

11. IIS BAT CGI script: no output from programs called

12. Win-CGI / CGI.BAS & Inter_Main -- Where is it??

13. How to enable a cgi-local for CGI scripts in virtual hosts (Apache win32)?