summaryrefslogtreecommitdiffabout
path: root/src/sitecing-plaincgi.cc
Unidiff
Diffstat (limited to 'src/sitecing-plaincgi.cc') (more/less context) (show whitespace changes)
-rw-r--r--src/sitecing-plaincgi.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sitecing-plaincgi.cc b/src/sitecing-plaincgi.cc
index 3bd291a..2f93cc5 100644
--- a/src/sitecing-plaincgi.cc
+++ b/src/sitecing-plaincgi.cc
@@ -47,13 +47,13 @@ void process_request(configuration& config) {
47 string action; 47 string action;
48 config_options::action_handler_t *action_handler; 48 config_options::action_handler_t *action_handler;
49 plaincgi_interface ci; 49 plaincgi_interface ci;
50 cgi_gateway gw(ci); 50 cgi_gateway gw(ci);
51 scif.prepare(&gw); 51 scif.prepare(&gw);
52 try { 52 try {
53 component_path = normalize_path(gw.path_info(),strip_leading_slash|strip_trailing_slash); 53 component_path = konforka::normalize_path(gw.path_info(),konforka::strip_leading_slash|konforka::strip_trailing_slash);
54 string full_component_path; 54 string full_component_path;
55 string sitecing_path_info; 55 string sitecing_path_info;
56 while(true) { 56 while(true) {
57 full_component_path = config.root_source+'/'+component_path; 57 full_component_path = config.root_source+'/'+component_path;
58 if(!access(full_component_path.c_str(),F_OK)) 58 if(!access(full_component_path.c_str(),F_OK))
59 break; 59 break;
@@ -66,13 +66,13 @@ void process_request(configuration& config) {
66 ci.metavars["SITECING_PATH_INFO"]=sitecing_path_info; 66 ci.metavars["SITECING_PATH_INFO"]=sitecing_path_info;
67 action = component_path; 67 action = component_path;
68 action_handler = config.lookup_action_handler(component_path); 68 action_handler = config.lookup_action_handler(component_path);
69 if(action_handler) { 69 if(action_handler) {
70 action = action_handler->action; 70 action = action_handler->action;
71 } 71 }
72 string pwd = dir_name(full_component_path); 72 string pwd = konforka::dir_name(full_component_path);
73 if(chdir(pwd.c_str())) 73 if(chdir(pwd.c_str()))
74 throw konforka::exception(CODEPOINT,"failed to chdir() into document's directory"); 74 throw konforka::exception(CODEPOINT,"failed to chdir() into document's directory");
75 so_component soc = ss.fetch(action,&scif); 75 so_component soc = ss.fetch(action,&scif);
76 if(action_handler) { 76 if(action_handler) {
77 soc.ac->run(__magic_action, 77 soc.ac->run(__magic_action,
78 config.root_source.c_str(), config.root_intermediate.c_str(), config.root_so.c_str(), 78 config.root_source.c_str(), config.root_intermediate.c_str(), config.root_so.c_str(),