Fossil SCM

'skin:' CGI config directive now accepts an empty value for consistency with the --skin CLI flag.

stephan 2022-09-29 09:25 trunk
Commit 6362a98fa67e1d7dddab2872aab419f657be3ae05ab563103c16b630c7a194ea
1 file changed +4 -2
+4 -2
--- src/main.c
+++ src/main.c
@@ -2450,20 +2450,22 @@
24502450
*/
24512451
cgi_setenv("HOME", blob_str(&value));
24522452
blob_reset(&value);
24532453
continue;
24542454
}
2455
- if( blob_eq(&key, "skin:") && blob_token(&line, &value) ){
2455
+ if( blob_eq(&key, "skin:") ){
24562456
/* skin: LABEL
24572457
**
24582458
** Use one of the built-in skins defined by LABEL. LABEL is the
24592459
** name of the subdirectory under the skins/ directory that holds
24602460
** the elements of the built-in skin. If LABEL does not match,
24612461
** this directive is a silent no-op. It may alternately be
24622462
** an absolute path to a directory which holds skin definition
2463
- ** files (header.txt, footer.txt, etc.).
2463
+ ** files (header.txt, footer.txt, etc.). If LABEL is empty,
2464
+ ** the skin stored in the CONFIG db table is used.
24642465
*/
2466
+ blob_token(&line, &value);
24652467
fossil_free(skin_use_alternative(blob_str(&value), 1));
24662468
blob_reset(&value);
24672469
continue;
24682470
}
24692471
if( blob_eq(&key, "jsmode:") && blob_token(&line, &value) ){
24702472
--- src/main.c
+++ src/main.c
@@ -2450,20 +2450,22 @@
2450 */
2451 cgi_setenv("HOME", blob_str(&value));
2452 blob_reset(&value);
2453 continue;
2454 }
2455 if( blob_eq(&key, "skin:") && blob_token(&line, &value) ){
2456 /* skin: LABEL
2457 **
2458 ** Use one of the built-in skins defined by LABEL. LABEL is the
2459 ** name of the subdirectory under the skins/ directory that holds
2460 ** the elements of the built-in skin. If LABEL does not match,
2461 ** this directive is a silent no-op. It may alternately be
2462 ** an absolute path to a directory which holds skin definition
2463 ** files (header.txt, footer.txt, etc.).
 
2464 */
 
2465 fossil_free(skin_use_alternative(blob_str(&value), 1));
2466 blob_reset(&value);
2467 continue;
2468 }
2469 if( blob_eq(&key, "jsmode:") && blob_token(&line, &value) ){
2470
--- src/main.c
+++ src/main.c
@@ -2450,20 +2450,22 @@
2450 */
2451 cgi_setenv("HOME", blob_str(&value));
2452 blob_reset(&value);
2453 continue;
2454 }
2455 if( blob_eq(&key, "skin:") ){
2456 /* skin: LABEL
2457 **
2458 ** Use one of the built-in skins defined by LABEL. LABEL is the
2459 ** name of the subdirectory under the skins/ directory that holds
2460 ** the elements of the built-in skin. If LABEL does not match,
2461 ** this directive is a silent no-op. It may alternately be
2462 ** an absolute path to a directory which holds skin definition
2463 ** files (header.txt, footer.txt, etc.). If LABEL is empty,
2464 ** the skin stored in the CONFIG db table is used.
2465 */
2466 blob_token(&line, &value);
2467 fossil_free(skin_use_alternative(blob_str(&value), 1));
2468 blob_reset(&value);
2469 continue;
2470 }
2471 if( blob_eq(&key, "jsmode:") && blob_token(&line, &value) ){
2472

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button