Fossil SCM

If the special "ckout" of the "/doc" webpage is used and the server is not within a local check-out, then automatically convert "ckout" to "tip".

drh 2009-08-15 12:18 trunk
Commit 292e585661b01026cf550a6000311947c64d4e75
1 file changed +3
+3
--- src/doc.c
+++ src/doc.c
@@ -348,10 +348,13 @@
348348
zBaseline[i] = 0;
349349
zName += i;
350350
while( zName[0]=='/' ){ zName++; }
351351
if( !file_is_simple_pathname(zName) ){
352352
goto doc_not_found;
353
+ }
354
+ if( strcmp(zBaseline,"ckout")==0 && db_open_local()==0 ){
355
+ strcpy(zBaseline,"tip");
353356
}
354357
if( strcmp(zBaseline,"ckout")==0 ){
355358
/* Read from the local checkout */
356359
char *zFullpath;
357360
db_must_be_within_tree();
358361
--- src/doc.c
+++ src/doc.c
@@ -348,10 +348,13 @@
348 zBaseline[i] = 0;
349 zName += i;
350 while( zName[0]=='/' ){ zName++; }
351 if( !file_is_simple_pathname(zName) ){
352 goto doc_not_found;
 
 
 
353 }
354 if( strcmp(zBaseline,"ckout")==0 ){
355 /* Read from the local checkout */
356 char *zFullpath;
357 db_must_be_within_tree();
358
--- src/doc.c
+++ src/doc.c
@@ -348,10 +348,13 @@
348 zBaseline[i] = 0;
349 zName += i;
350 while( zName[0]=='/' ){ zName++; }
351 if( !file_is_simple_pathname(zName) ){
352 goto doc_not_found;
353 }
354 if( strcmp(zBaseline,"ckout")==0 && db_open_local()==0 ){
355 strcpy(zBaseline,"tip");
356 }
357 if( strcmp(zBaseline,"ckout")==0 ){
358 /* Read from the local checkout */
359 char *zFullpath;
360 db_must_be_within_tree();
361

Keyboard Shortcuts

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