Fossil SCM
update from trunk
Commit
616a423b15c269cc033f9683584e7379a0d0cdcb
Parent
e5bf291e1c9fdfc…
3 files changed
+5
+2
-2
+2
-2
+5
| --- src/setup.c | ||
| +++ src/setup.c | ||
| @@ -938,10 +938,15 @@ | ||
| 938 | 938 | @ <blockquote><p>%h(g.zBaseURL)/home</p></blockquote> |
| 939 | 939 | @ |
| 940 | 940 | @ <p>The default "/home" page displays a Wiki page with the same name |
| 941 | 941 | @ as the Project Name specified above. Some sites prefer to redirect |
| 942 | 942 | @ to a documentation page (ex: "/doc/tip/index.wiki") or to "/timeline".</p> |
| 943 | + @ | |
| 944 | + @ <p>Note: To avoid a redirect loop or other problems, this entry must | |
| 945 | + @ begin with "/" and it must specify a valid page. For example, | |
| 946 | + @ "<b>/home</b>" will work but "<b>home</b>" will not, since it omits the | |
| 947 | + @ leading "/".</p> | |
| 943 | 948 | @ <hr /> |
| 944 | 949 | onoff_attribute("Use HTML as wiki markup language", |
| 945 | 950 | "wiki-use-html", "wiki-use-html", 0); |
| 946 | 951 | @ <p>Use HTML as the wiki markup language. Wiki links will still be parsed |
| 947 | 952 | @ but all other wiki formatting will be ignored. This option is helpful |
| 948 | 953 |
| --- src/setup.c | |
| +++ src/setup.c | |
| @@ -938,10 +938,15 @@ | |
| 938 | @ <blockquote><p>%h(g.zBaseURL)/home</p></blockquote> |
| 939 | @ |
| 940 | @ <p>The default "/home" page displays a Wiki page with the same name |
| 941 | @ as the Project Name specified above. Some sites prefer to redirect |
| 942 | @ to a documentation page (ex: "/doc/tip/index.wiki") or to "/timeline".</p> |
| 943 | @ <hr /> |
| 944 | onoff_attribute("Use HTML as wiki markup language", |
| 945 | "wiki-use-html", "wiki-use-html", 0); |
| 946 | @ <p>Use HTML as the wiki markup language. Wiki links will still be parsed |
| 947 | @ but all other wiki formatting will be ignored. This option is helpful |
| 948 |
| --- src/setup.c | |
| +++ src/setup.c | |
| @@ -938,10 +938,15 @@ | |
| 938 | @ <blockquote><p>%h(g.zBaseURL)/home</p></blockquote> |
| 939 | @ |
| 940 | @ <p>The default "/home" page displays a Wiki page with the same name |
| 941 | @ as the Project Name specified above. Some sites prefer to redirect |
| 942 | @ to a documentation page (ex: "/doc/tip/index.wiki") or to "/timeline".</p> |
| 943 | @ |
| 944 | @ <p>Note: To avoid a redirect loop or other problems, this entry must |
| 945 | @ begin with "/" and it must specify a valid page. For example, |
| 946 | @ "<b>/home</b>" will work but "<b>home</b>" will not, since it omits the |
| 947 | @ leading "/".</p> |
| 948 | @ <hr /> |
| 949 | onoff_attribute("Use HTML as wiki markup language", |
| 950 | "wiki-use-html", "wiki-use-html", 0); |
| 951 | @ <p>Use HTML as the wiki markup language. Wiki links will still be parsed |
| 952 | @ but all other wiki formatting will be ignored. This option is helpful |
| 953 |
+2
-2
| --- src/wiki.c | ||
| +++ src/wiki.c | ||
| @@ -85,12 +85,12 @@ | ||
| 85 | 85 | login_check_credentials(); |
| 86 | 86 | if( !g.okRdWiki ){ |
| 87 | 87 | cgi_redirectf("%s/login?g=%s/home", g.zBaseURL, g.zBaseURL); |
| 88 | 88 | } |
| 89 | 89 | if( zIndexPage ){ |
| 90 | - while( zIndexPage[0]=='/' ) zIndexPage++; | |
| 91 | - if( strcmp(zIndexPage, P("PATH_INFO"))==0 ) zIndexPage = 0; | |
| 90 | + const char *zPathInfo = P("PATH_INFO"); | |
| 91 | + if( strcmp(zIndexPage, zPathInfo)==0 ) zIndexPage = 0; | |
| 92 | 92 | } |
| 93 | 93 | if( zIndexPage ){ |
| 94 | 94 | cgi_redirectf("%s/%s", g.zBaseURL, zIndexPage); |
| 95 | 95 | } |
| 96 | 96 | if( zPageName ){ |
| 97 | 97 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -85,12 +85,12 @@ | |
| 85 | login_check_credentials(); |
| 86 | if( !g.okRdWiki ){ |
| 87 | cgi_redirectf("%s/login?g=%s/home", g.zBaseURL, g.zBaseURL); |
| 88 | } |
| 89 | if( zIndexPage ){ |
| 90 | while( zIndexPage[0]=='/' ) zIndexPage++; |
| 91 | if( strcmp(zIndexPage, P("PATH_INFO"))==0 ) zIndexPage = 0; |
| 92 | } |
| 93 | if( zIndexPage ){ |
| 94 | cgi_redirectf("%s/%s", g.zBaseURL, zIndexPage); |
| 95 | } |
| 96 | if( zPageName ){ |
| 97 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -85,12 +85,12 @@ | |
| 85 | login_check_credentials(); |
| 86 | if( !g.okRdWiki ){ |
| 87 | cgi_redirectf("%s/login?g=%s/home", g.zBaseURL, g.zBaseURL); |
| 88 | } |
| 89 | if( zIndexPage ){ |
| 90 | const char *zPathInfo = P("PATH_INFO"); |
| 91 | if( strcmp(zIndexPage, zPathInfo)==0 ) zIndexPage = 0; |
| 92 | } |
| 93 | if( zIndexPage ){ |
| 94 | cgi_redirectf("%s/%s", g.zBaseURL, zIndexPage); |
| 95 | } |
| 96 | if( zPageName ){ |
| 97 |
+2
-2
| --- src/wiki.c | ||
| +++ src/wiki.c | ||
| @@ -85,12 +85,12 @@ | ||
| 85 | 85 | login_check_credentials(); |
| 86 | 86 | if( !g.okRdWiki ){ |
| 87 | 87 | cgi_redirectf("%s/login?g=%s/home", g.zBaseURL, g.zBaseURL); |
| 88 | 88 | } |
| 89 | 89 | if( zIndexPage ){ |
| 90 | - while( zIndexPage[0]=='/' ) zIndexPage++; | |
| 91 | - if( strcmp(zIndexPage, P("PATH_INFO"))==0 ) zIndexPage = 0; | |
| 90 | + const char *zPathInfo = P("PATH_INFO"); | |
| 91 | + if( strcmp(zIndexPage, zPathInfo)==0 ) zIndexPage = 0; | |
| 92 | 92 | } |
| 93 | 93 | if( zIndexPage ){ |
| 94 | 94 | cgi_redirectf("%s/%s", g.zBaseURL, zIndexPage); |
| 95 | 95 | } |
| 96 | 96 | if( zPageName ){ |
| 97 | 97 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -85,12 +85,12 @@ | |
| 85 | login_check_credentials(); |
| 86 | if( !g.okRdWiki ){ |
| 87 | cgi_redirectf("%s/login?g=%s/home", g.zBaseURL, g.zBaseURL); |
| 88 | } |
| 89 | if( zIndexPage ){ |
| 90 | while( zIndexPage[0]=='/' ) zIndexPage++; |
| 91 | if( strcmp(zIndexPage, P("PATH_INFO"))==0 ) zIndexPage = 0; |
| 92 | } |
| 93 | if( zIndexPage ){ |
| 94 | cgi_redirectf("%s/%s", g.zBaseURL, zIndexPage); |
| 95 | } |
| 96 | if( zPageName ){ |
| 97 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -85,12 +85,12 @@ | |
| 85 | login_check_credentials(); |
| 86 | if( !g.okRdWiki ){ |
| 87 | cgi_redirectf("%s/login?g=%s/home", g.zBaseURL, g.zBaseURL); |
| 88 | } |
| 89 | if( zIndexPage ){ |
| 90 | const char *zPathInfo = P("PATH_INFO"); |
| 91 | if( strcmp(zIndexPage, zPathInfo)==0 ) zIndexPage = 0; |
| 92 | } |
| 93 | if( zIndexPage ){ |
| 94 | cgi_redirectf("%s/%s", g.zBaseURL, zIndexPage); |
| 95 | } |
| 96 | if( zPageName ){ |
| 97 |