[svn:mod_parrot] r320 - mod_parrot/trunk/src

[email protected] Sun, 20 Jan 2008 07:34:39 -0800 (PST)
Newsgroups perl.cvs.mod_parrot
Message-ID <[email protected]>
Author: jhorwitz
Date: Sun Jan 20 07:34:38 2008
New Revision: 320

Modified:
   mod_parrot/trunk/src/mod_parrot.c

Log:
set default HLL where appropriate



Modified: mod_parrot/trunk/src/mod_parrot.c
==============================================================================
--- mod_parrot/trunk/src/mod_parrot.c	(original)
+++ mod_parrot/trunk/src/mod_parrot.c	Sun Jan 20 07:34:38 2008
@@ -189,7 +189,7 @@
     hll = dircfg->x->hll ? dircfg->x->hll : dircfg->hll; \
     if (!hll) { \
         if (!(hll = (get_request_hll(r, r->handler, r->content_type)))) { \
-            return DECLINED; \
+            hll = MODPARROT_DEFAULT_HLL; \
         } \
     } \
     hll_handler = dircfg->x ? dircfg->x->id : (char *)r->handler;
@@ -226,7 +226,8 @@
     }
     if (!hll) {
         if (!(hll = (get_request_hll(r, r->handler, r->content_type)))) {
-            return DECLINED;
+            if (!dircfg->handler) return DECLINED;
+            hll = MODPARROT_DEFAULT_HLL;
         }
     }
 
@@ -296,7 +297,7 @@
     /* call HLL handler */
     sub = "pre_connection_handler";
     hll = cfg->pre_connection_handler->hll ?
-        cfg->pre_connection_handler->hll : "PIR";
+        cfg->pre_connection_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->pre_connection_handler->id, &handler_status)) {
@@ -341,7 +342,7 @@
     /* call HLL handler */
     sub = "map_to_storage_handler";
     hll = cfg->map_to_storage_handler->hll ?
-        cfg->map_to_storage_handler->hll : "PIR";
+        cfg->map_to_storage_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->map_to_storage_handler->id, &handler_status)) {
@@ -428,7 +429,7 @@
     /* call HLL handler */
     sub = "post_read_request_handler";
     hll = cfg->post_read_request_handler->hll ?
-        cfg->post_read_request_handler->hll : "PIR";
+        cfg->post_read_request_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->post_read_request_handler->id, &handler_status)) {
@@ -469,7 +470,7 @@
     /* call HLL handler */
     sub = "process_connection_handler";
     hll = cfg->process_connection_handler->hll ?
-        cfg->process_connection_handler->hll : "PIR";
+        cfg->process_connection_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->process_connection_handler->id, &handler_status)) {
@@ -513,7 +514,8 @@
 
     /* call HLL handler */
     sub = "child_init_handler";
-    hll = cfg->child_init_handler->hll ?  cfg->child_init_handler->hll : "PIR";
+    hll = cfg->child_init_handler->hll ?
+        cfg->child_init_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->child_init_handler->id, &handler_status)) {
@@ -554,7 +556,8 @@
 
     /* call HLL handler */
     sub = "trans_handler";
-    hll = cfg->trans_handler->hll ?  cfg->trans_handler->hll : "PIR";
+    hll = cfg->trans_handler->hll ? 
+        cfg->trans_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->trans_handler->id, &handler_status)) {
@@ -857,7 +860,8 @@
 
     /* call HLL handler */
     sub = "post_config_handler";
-    hll = cfg->post_config_handler->hll ? cfg->post_config_handler->hll : "PIR";
+    hll = cfg->post_config_handler->hll ?
+        cfg->post_config_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->post_config_handler->id, &handler_status)) {
@@ -944,7 +948,8 @@
 
     /* call HLL handler */
     sub = "open_logs_handler";
-    hll = cfg->open_logs_handler->hll ?  cfg->open_logs_handler->hll : "PIR";
+    hll = cfg->open_logs_handler->hll ?
+        cfg->open_logs_handler->hll : MODPARROT_DEFAULT_HLL;
 
     if (!modparrot_hll_handler(ctxp->interp, hll, sub,
         cfg->open_logs_handler->id, &handler_status)) {