| 112 return 1; |
112 return 1; |
| 113 } |
113 } |
| 114 } |
114 } |
| 115 |
115 |
| 116 if(cxListAdd(location->rewrite, rule)) { |
116 if(cxListAdd(location->rewrite, rule)) { |
| |
117 return 1; |
| |
118 } |
| |
119 } else if(!cx_strcasecmp(name, "ProxyPass")) { |
| |
120 location->config.proxy_url = cx_strdup_a(a, dir->args->value); |
| |
121 if(!location->config.proxy_url.ptr) { |
| |
122 return 1; |
| |
123 } |
| |
124 } else if(!cx_strcasecmp(name, "ProxyHeader")) { |
| |
125 if(!location->config.proxy_headers) { |
| |
126 location->config.proxy_headers = cxLinkedListCreate(a, CX_STORE_POINTERS); |
| |
127 if(!location->config.proxy_headers) { |
| |
128 return 1; |
| |
129 } |
| |
130 } |
| |
131 StringTemplate *header_tpl = string_template_compile(a, cx_strcast(dir->args->value)); |
| |
132 if(!header_tpl) { |
| |
133 return 1; |
| |
134 } |
| |
135 if(cxListAdd(location->config.proxy_headers, header_tpl)) { |
| |
136 string_template_free(header_tpl); |
| 117 return 1; |
137 return 1; |
| 118 } |
138 } |
| 119 } |
139 } |
| 120 |
140 |
| 121 return 0; |
141 return 0; |