ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/repos/Bender/Bender.cpp
(Generate patch)

Comparing Bender/Bender.cpp (file contents):
Revision 627 by douglas, 2005-12-24T22:30:44-08:00 vs.
Revision 909 by douglas, 2007-04-29T20:05:49-07:00

# Line 28 | Line 28 | public:
28  
29   struct Environment
30   {
31 <        cse::String get(const cse::String& name) { try { return api::TheEnvironment.Get(name); } catch (ext::Exception) { return cse::String(); } }
31 >        cse::String get(const cse::String& name)
32 >        {
33 >                try
34 >                {
35 >                        return api::TheEnvironment.Get(name);
36 >                }
37 >                catch (ext::Exception)
38 >                {
39 >                        return cse::String();
40 >                }
41 >        }
42   } env;
43  
44   int Main(const app::Options& options)
# Line 43 | Line 53 | Bender::Bender()
53          cse::String path(env.get(_B("PATH_TRANSLATED")));
54          api::Pcre::RegEx script(_S<ios::String>() << _B("^") << env.get(_B("SCRIPT_NAME")));
55  
56 <        if (!path.IsEmpty() && script(env.get(_B("REQUEST_URI"))))
56 >        if (!path.IsEmpty() && !script(env.get(_B("REQUEST_URI"))))
57          {
58                  try
59                  {
# Line 66 | Line 76 | Bender::Bender()
76                                  << env.get(_B("SERVER_SIGNATURE")) << _B("</body></html>\n");
77                  }
78          }
79 <        else api::Cout << _B("Location: http://computers.douglasthrift.net/bender.xml\r\n\r\n");
79 >        else
80 >                api::Cout << _B("Location: http://computers.douglasthrift.net/bender.xml\r\n\r\n");
81   }
82  
83   void Bender::bend(const cse::String& path, const cse::String& agent)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines