| Move $local_path deffinition to a more correct place. - swerc - anselm's simple… | |
| git clone git://git.suckless.org/swerc | |
| Log | |
| Files | |
| Refs | |
| README | |
| --- | |
| commit 566786624b6f2c0d512c9f661e4f033e4914e355 | |
| parent 9149ea390ce121d63c682d6ad91639bff57dbd09 | |
| Author: [email protected] <unknown> | |
| Date: Wed, 31 Dec 2008 00:16:47 +0100 | |
| Move $local_path deffinition to a more correct place. | |
| Diffstat: | |
| M bin/werc.rc | 2 +- | |
| 1 file changed, 1 insertion(+), 1 deletion(-) | |
| --- | |
| diff --git a/bin/werc.rc b/bin/werc.rc | |
| @@ -185,6 +185,7 @@ werc_root=`{pwd} | |
| # Parse request URL | |
| # NOTE: $REQUEST_URI is not officially in CGI 1.1, but seems to be de-facto | |
| req_path=`{echo -n $REQUEST_URI | sed 's/\?.*//; s/'^$forbidden_uri_chars^'//g… | |
| +local_path=$sitedir$req_path | |
| ifs='/' { args=`{echo -n $req_path} } | |
| # Hack: preload post data so we can access it from templates where cgi's stdin… | |
| @@ -231,7 +232,6 @@ if not | |
| pageTitle=$"pageTitle^' | '^$"siteTitle^' '^$"siteSubTitle | |
| -local_path=$sitedir$req_path | |
| if(test -d $local_path) { | |
| if(! ~ $local_path */) | |
| perm_redirect $req_path^'/' |