author | Michael Krelin <hacker@klever.net> | 2005-02-13 14:02:29 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2005-02-13 14:02:29 (UTC) |
commit | 4fa4a0071ef9a04c02f8934b2e1d3b7628a65c80 (patch) (unidiff) | |
tree | 47f2e6866ab812985ae9e6adbcea8bb785fa0403 /src/plaincgi.cc | |
parent | ff4b919683537625f693eedf53006364d0f8444d (diff) | |
download | kingate-4fa4a0071ef9a04c02f8934b2e1d3b7628a65c80.zip kingate-4fa4a0071ef9a04c02f8934b2e1d3b7628a65c80.tar.gz kingate-4fa4a0071ef9a04c02f8934b2e1d3b7628a65c80.tar.bz2 |
1. Support for 'plain' CGI
2. Made fastcgi support optional
3. bumped version to 0.0.1
4. doxygen documentation target 'dox' is not built for 'all' now
-rw-r--r-- | src/plaincgi.cc | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/plaincgi.cc b/src/plaincgi.cc new file mode 100644 index 0000000..6934748 --- a/dev/null +++ b/src/plaincgi.cc | |||
@@ -0,0 +1,27 @@ | |||
1 | #include <unistd.h> | ||
2 | #include <sys/types.h> | ||
3 | #include <sys/stat.h> | ||
4 | #include "kingate/plaincgi.h" | ||
5 | #include "kingate/exception.h" | ||
6 | |||
7 | namespace kingate { | ||
8 | |||
9 | plaincgi_interface::plaincgi_interface() { | ||
10 | for(char **p = environ; *p; p++) { | ||
11 | const char *e = strchr(*p,'='); | ||
12 | if(!e){ | ||
13 | // XXX: check if we have it already? | ||
14 | metavars[*p] = string(0); | ||
15 | }else{ | ||
16 | int l = e-*p; e++; | ||
17 | // XXX: check if we have it already? | ||
18 | metavars[string(*p,l)]=e; | ||
19 | } | ||
20 | } | ||
21 | } | ||
22 | plaincgi_interface::~plaincgi_interface() { | ||
23 | cout.flush(); | ||
24 | cerr.flush(); | ||
25 | } | ||
26 | |||
27 | } | ||