Mark,

Thanks for the suggestion.
I read thru the differences and nothing specific stood out as the root of my problem.
I noticed that hash tables are replaced by array lists;
a new option is available to indicate if the shell environment should be passed (or not) --
I think I need to set that;
the release notes indicate that a patch was made to prevent deadlock between stderr and
large stdout data .

This patch solves this problem by having a single loop which
reads stderr if it's ready, or stdout if ready.
Fixes Bug 12041


My web-application is a combination of html, javascript, perl scripts, c++ programs, and java applets.
My project is working rewriting this web-application as a J2EE  application.
However, we still need to use the older web-application for some time..

So, using the default executable in the cgi definition for tomcat/conf/web.xml ,
the perl scripts work fine.
When I execute any of the c++ programs, I get a white (that is, blank, empty)
browser window in return.
When I look at the tomcat 5.0  logs, the findCGI and runCGI seem to
determine the cgi name, path and parameters correctly.
However, I see a message that states runCGI received "\x7F" on stderr .
I am guessing that perl attempted to read the c++ executable as a file (so that it could interpret it) because the first byte of every c++ program is "\x7F" (that is, accounting for little-endian, since
the system is running on a Dell 1750 running Redhat AS 3.0.)

I can fake out the system by creating a cshell-script with the same name as the c++ executable and statically call the c++ cgi from within the cshell-script. The cshell-script is executed successfully, the cshell-script executes the c++ cgi executable successfully and my expected output comes back
to the browser window.

Any suggestions?

Linda

Mark Thomas wrote:

Linda Solomon wrote:
I followed the instructions for configuring tomcat 5 for cgi.
However, tomcat 5 contains a new xml variable:
executable - The of the executable to be used to run the script. Default
is perl.

Using the default allows the perl cgis to work fine, but the c++ cgi's
do not work.
This is unlikely to be a factor. Before it was configurable it was
hard-coded to perl so if you leave it as the default there should be
no functional change.

There are, however, a whole stack of other changes that may be a
factor. The following (rather long) URL should show you the changes.
http://svn.apache.org/viewcvs.cgi/tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/servlets/CGIServlet.java?p1=tomcat%2Fcontainer%2Fcatalina%2Ftrunk%2Fcatalina%2Fsrc%2Fshare%2Forg%2Fapache%2Fcatalina%2Fservlets%2FCGIServlet.java&rev=366305&r1=302487&r2=366305&diff_format=h

Mark


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Reply via email to