Fossil SCM

Removing the 'd' link on the annotate page for lines introduced in a checkin with the parent don't having that file.

viriketo 2012-02-17 21:47 annotate_links
Commit 4036b5df51a4be9aae4f433a03c199b6570ce57a
1 file changed +15 -7
+15 -7
--- src/diff.c
+++ src/diff.c
@@ -1784,17 +1784,25 @@
17841784
const char *zUuidFile = db_column_text(&q, 2);
17851785
const char *zUuidParentFile = db_column_text(&q, 3);
17861786
const char *zDate = db_column_text(&q, 4);
17871787
const char *zUser = db_column_text(&q, 5);
17881788
if( webLabel ){
1789
- zLabel = mprintf(
1790
- "<a href='%s/info/%s' %s>%.10s</a> "
1791
- "<a href='%s/fdiff?v1=%s&v2=%s' %s>d</a> "
1792
- "%s %9.9s",
1793
- g.zTop, zUuid, zInfoTarget, zUuid,
1794
- g.zTop, zUuidParentFile, zUuidFile, zDiffTarget,
1795
- zDate, zUser);
1789
+ if (zUuidParentFile) {
1790
+ zLabel = mprintf(
1791
+ "<a href='%s/info/%s' %s>%.10s</a> "
1792
+ "<a href='%s/fdiff?v1=%s&v2=%s' %s>d</a> "
1793
+ "%s %9.9s",
1794
+ g.zTop, zUuid, zInfoTarget, zUuid,
1795
+ g.zTop, zUuidParentFile, zUuidFile, zDiffTarget,
1796
+ zDate, zUser);
1797
+ }else{
1798
+ zLabel = mprintf(
1799
+ "<a href='%s/info/%s' %s>%.10s</a> "
1800
+ "%s %9.9s",
1801
+ g.zTop, zUuid, zInfoTarget, zUuid,
1802
+ zDate, zUser);
1803
+ }
17961804
}else{
17971805
zLabel = mprintf("%.10s %s %9.9s", zUuid, zDate, zUser);
17981806
}
17991807
p->nVers++;
18001808
p->azVers = fossil_realloc(p->azVers, p->nVers*sizeof(p->azVers[0]) );
18011809
--- src/diff.c
+++ src/diff.c
@@ -1784,17 +1784,25 @@
1784 const char *zUuidFile = db_column_text(&q, 2);
1785 const char *zUuidParentFile = db_column_text(&q, 3);
1786 const char *zDate = db_column_text(&q, 4);
1787 const char *zUser = db_column_text(&q, 5);
1788 if( webLabel ){
1789 zLabel = mprintf(
1790 "<a href='%s/info/%s' %s>%.10s</a> "
1791 "<a href='%s/fdiff?v1=%s&v2=%s' %s>d</a> "
1792 "%s %9.9s",
1793 g.zTop, zUuid, zInfoTarget, zUuid,
1794 g.zTop, zUuidParentFile, zUuidFile, zDiffTarget,
1795 zDate, zUser);
 
 
 
 
 
 
 
 
1796 }else{
1797 zLabel = mprintf("%.10s %s %9.9s", zUuid, zDate, zUser);
1798 }
1799 p->nVers++;
1800 p->azVers = fossil_realloc(p->azVers, p->nVers*sizeof(p->azVers[0]) );
1801
--- src/diff.c
+++ src/diff.c
@@ -1784,17 +1784,25 @@
1784 const char *zUuidFile = db_column_text(&q, 2);
1785 const char *zUuidParentFile = db_column_text(&q, 3);
1786 const char *zDate = db_column_text(&q, 4);
1787 const char *zUser = db_column_text(&q, 5);
1788 if( webLabel ){
1789 if (zUuidParentFile) {
1790 zLabel = mprintf(
1791 "<a href='%s/info/%s' %s>%.10s</a> "
1792 "<a href='%s/fdiff?v1=%s&v2=%s' %s>d</a> "
1793 "%s %9.9s",
1794 g.zTop, zUuid, zInfoTarget, zUuid,
1795 g.zTop, zUuidParentFile, zUuidFile, zDiffTarget,
1796 zDate, zUser);
1797 }else{
1798 zLabel = mprintf(
1799 "<a href='%s/info/%s' %s>%.10s</a> "
1800 "%s %9.9s",
1801 g.zTop, zUuid, zInfoTarget, zUuid,
1802 zDate, zUser);
1803 }
1804 }else{
1805 zLabel = mprintf("%.10s %s %9.9s", zUuid, zDate, zUser);
1806 }
1807 p->nVers++;
1808 p->azVers = fossil_realloc(p->azVers, p->nVers*sizeof(p->azVers[0]) );
1809

Keyboard Shortcuts

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