Fossil SCM

Fix over-length source code lines in import.c.

drh 2020-09-11 12:20 trunk
Commit 8d9d8654a39db1893df0b79da63259a47e51fb76b35edd69769f1f3146e9a4af
1 file changed +4 -3
+4 -3
--- src/import.c
+++ src/import.c
@@ -571,11 +571,11 @@
571571
**
572572
** None of the above is explained in the git-fast-export
573573
** documentation. We had to figure it out via trial and error.
574574
*/
575575
for(i=5; i<strlen(zRefName) && zRefName[i]!='/'; i++){}
576
- gg.tagCommit = strncmp(&zRefName[5], "tags", 4)==0; /* True for pattern B */
576
+ gg.tagCommit = strncmp(&zRefName[5], "tags", 4)==0; /* pattern B */
577577
if( zRefName[i+1]!=0 ) zRefName += i+1;
578578
if( fossil_strcmp(zRefName, "master")==0 ) zRefName = ggit.zMasterName;
579579
gg.zBranch = fossil_strdup(zRefName);
580580
gg.fromLoaded = 0;
581581
}else
@@ -657,11 +657,11 @@
657657
secSince1970 = 0;
658658
for(zTo++; fossil_isdigit(*zTo); zTo++){
659659
secSince1970 = secSince1970*10 + *zTo - '0';
660660
}
661661
fossil_free(gg.zDate);
662
- gg.zDate = db_text(0, "SELECT datetime(%lld, 'unixepoch')", secSince1970);
662
+ gg.zDate = db_text(0, "SELECT datetime(%lld, 'unixepoch')",secSince1970);
663663
gg.zDate[10] = 'T';
664664
}else
665665
if( strncmp(zLine, "from ", 5)==0 ){
666666
trim_newline(&zLine[5]);
667667
fossil_free(gg.zFromMark);
@@ -1349,11 +1349,12 @@
13491349
db_prepare(&addRev,
13501350
"INSERT OR IGNORE INTO xrevisions (trev, tbranch) VALUES(:rev, :branch)"
13511351
);
13521352
db_prepare(&cpyPath,
13531353
"INSERT INTO xfiles (tpath, tbranch, tuuid, tperm)"
1354
- " SELECT :path||:sep||substr(filename, length(:srcpath)+2), :branch, uuid, perm"
1354
+ " SELECT :path||:sep||substr(filename,"
1355
+ " length(:srcpath)+2), :branch, uuid, perm"
13551356
" FROM xfoci"
13561357
" WHERE checkinID=:rid"
13571358
" AND filename>:srcpath||'/'"
13581359
" AND filename<:srcpath||'0'"
13591360
);
13601361
--- src/import.c
+++ src/import.c
@@ -571,11 +571,11 @@
571 **
572 ** None of the above is explained in the git-fast-export
573 ** documentation. We had to figure it out via trial and error.
574 */
575 for(i=5; i<strlen(zRefName) && zRefName[i]!='/'; i++){}
576 gg.tagCommit = strncmp(&zRefName[5], "tags", 4)==0; /* True for pattern B */
577 if( zRefName[i+1]!=0 ) zRefName += i+1;
578 if( fossil_strcmp(zRefName, "master")==0 ) zRefName = ggit.zMasterName;
579 gg.zBranch = fossil_strdup(zRefName);
580 gg.fromLoaded = 0;
581 }else
@@ -657,11 +657,11 @@
657 secSince1970 = 0;
658 for(zTo++; fossil_isdigit(*zTo); zTo++){
659 secSince1970 = secSince1970*10 + *zTo - '0';
660 }
661 fossil_free(gg.zDate);
662 gg.zDate = db_text(0, "SELECT datetime(%lld, 'unixepoch')", secSince1970);
663 gg.zDate[10] = 'T';
664 }else
665 if( strncmp(zLine, "from ", 5)==0 ){
666 trim_newline(&zLine[5]);
667 fossil_free(gg.zFromMark);
@@ -1349,11 +1349,12 @@
1349 db_prepare(&addRev,
1350 "INSERT OR IGNORE INTO xrevisions (trev, tbranch) VALUES(:rev, :branch)"
1351 );
1352 db_prepare(&cpyPath,
1353 "INSERT INTO xfiles (tpath, tbranch, tuuid, tperm)"
1354 " SELECT :path||:sep||substr(filename, length(:srcpath)+2), :branch, uuid, perm"
 
1355 " FROM xfoci"
1356 " WHERE checkinID=:rid"
1357 " AND filename>:srcpath||'/'"
1358 " AND filename<:srcpath||'0'"
1359 );
1360
--- src/import.c
+++ src/import.c
@@ -571,11 +571,11 @@
571 **
572 ** None of the above is explained in the git-fast-export
573 ** documentation. We had to figure it out via trial and error.
574 */
575 for(i=5; i<strlen(zRefName) && zRefName[i]!='/'; i++){}
576 gg.tagCommit = strncmp(&zRefName[5], "tags", 4)==0; /* pattern B */
577 if( zRefName[i+1]!=0 ) zRefName += i+1;
578 if( fossil_strcmp(zRefName, "master")==0 ) zRefName = ggit.zMasterName;
579 gg.zBranch = fossil_strdup(zRefName);
580 gg.fromLoaded = 0;
581 }else
@@ -657,11 +657,11 @@
657 secSince1970 = 0;
658 for(zTo++; fossil_isdigit(*zTo); zTo++){
659 secSince1970 = secSince1970*10 + *zTo - '0';
660 }
661 fossil_free(gg.zDate);
662 gg.zDate = db_text(0, "SELECT datetime(%lld, 'unixepoch')",secSince1970);
663 gg.zDate[10] = 'T';
664 }else
665 if( strncmp(zLine, "from ", 5)==0 ){
666 trim_newline(&zLine[5]);
667 fossil_free(gg.zFromMark);
@@ -1349,11 +1349,12 @@
1349 db_prepare(&addRev,
1350 "INSERT OR IGNORE INTO xrevisions (trev, tbranch) VALUES(:rev, :branch)"
1351 );
1352 db_prepare(&cpyPath,
1353 "INSERT INTO xfiles (tpath, tbranch, tuuid, tperm)"
1354 " SELECT :path||:sep||substr(filename,"
1355 " length(:srcpath)+2), :branch, uuid, perm"
1356 " FROM xfoci"
1357 " WHERE checkinID=:rid"
1358 " AND filename>:srcpath||'/'"
1359 " AND filename<:srcpath||'0'"
1360 );
1361

Keyboard Shortcuts

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