1 |
On Tue, Feb 17, 2009 at 9:10 AM, Naga <nagatoro@×××××.com> wrote: |
2 |
> On Monday 16 February 2009 00:59:41 Kevin O'Gorman wrote: |
3 |
>> I've got a low-use CGI script on my web server. Aside from web |
4 |
>> crawlers, I usually see at most a few hits a week from |
5 |
>> people who share my hobby. |
6 |
>> |
7 |
>> I just found out it's been down for an unknown period of time because |
8 |
>> my Apache no longer does CGI scripting. |
9 |
>> I can't even get it to run the simplest possible C program. |
10 |
> |
11 |
> Not sure if this is related to your problem but I had a similar issue that was |
12 |
> caused by having "threads" as a USE flag for Apache. This has the effect that |
13 |
> the mod_cgi.so module isn't built, but the mod_cgid.so one is. |
14 |
> |
15 |
> /Regards |
16 |
> Naga |
17 |
> |
18 |
> |
19 |
|
20 |
Problem solved. It wasn't i18n, and it wasn't Python. |
21 |
|
22 |
Apparently somewhere along the line, apache started to provide a |
23 |
command-line argument to CGI programs. At least my Python script was |
24 |
getting an empty string in argv[1]. The script is picky about that, |
25 |
but had old code to handle it that worked only for the command-line. |
26 |
It did not expect to have any arguments at all when running as CGI. |
27 |
|
28 |
After fixing up error handling, and training it to ignore empty string |
29 |
parameters, the script runs just fine. Check it out at |
30 |
http://hex.kosmanor.com/hex-bin/board if you like the game of Hex. |
31 |
It's a hobby thing. |
32 |
|
33 |
++ kevin |
34 |
|
35 |
|
36 |
-- |
37 |
Kevin O'Gorman, PhD |