Fossil SCM
Cherry-pick [767b175d90]: Avoid references to private check-ins in Q-cards of public check-in manifests. This ensures consistent behavior regarding leakage of private check-in hashes, possibly generating phantoms on peer repositories, for P- and Q-cards.
Commit
52a66829d655ff35dc5245b664b86225438d7f46a8d183ac98268ece982d8564
Parent
658547aa7c4f40b…
2 files changed
+2
-3
+2
-3
+2
-3
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -1769,13 +1769,12 @@ | ||
| 1769 | 1769 | " WHERE (vmerge.id=-1 OR vmerge.id=-2)" |
| 1770 | 1770 | " ORDER BY 1"); |
| 1771 | 1771 | while( db_step(&q)==SQLITE_ROW ){ |
| 1772 | 1772 | const char *zCherrypickUuid = db_column_text(&q, 0); |
| 1773 | 1773 | int mid = db_column_int(&q, 1); |
| 1774 | - if( mid != vid ){ | |
| 1775 | - blob_appendf(pOut, "Q %s\n", zCherrypickUuid); | |
| 1776 | - } | |
| 1774 | + if( (!g.markPrivate && content_is_private(mid)) || (mid == vid) ) continue; | |
| 1775 | + blob_appendf(pOut, "Q %s\n", zCherrypickUuid); | |
| 1777 | 1776 | } |
| 1778 | 1777 | db_finalize(&q); |
| 1779 | 1778 | |
| 1780 | 1779 | if( p->pCksum ) blob_appendf(pOut, "R %b\n", p->pCksum); |
| 1781 | 1780 | zColor = p->zColor; |
| 1782 | 1781 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -1769,13 +1769,12 @@ | |
| 1769 | " WHERE (vmerge.id=-1 OR vmerge.id=-2)" |
| 1770 | " ORDER BY 1"); |
| 1771 | while( db_step(&q)==SQLITE_ROW ){ |
| 1772 | const char *zCherrypickUuid = db_column_text(&q, 0); |
| 1773 | int mid = db_column_int(&q, 1); |
| 1774 | if( mid != vid ){ |
| 1775 | blob_appendf(pOut, "Q %s\n", zCherrypickUuid); |
| 1776 | } |
| 1777 | } |
| 1778 | db_finalize(&q); |
| 1779 | |
| 1780 | if( p->pCksum ) blob_appendf(pOut, "R %b\n", p->pCksum); |
| 1781 | zColor = p->zColor; |
| 1782 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -1769,13 +1769,12 @@ | |
| 1769 | " WHERE (vmerge.id=-1 OR vmerge.id=-2)" |
| 1770 | " ORDER BY 1"); |
| 1771 | while( db_step(&q)==SQLITE_ROW ){ |
| 1772 | const char *zCherrypickUuid = db_column_text(&q, 0); |
| 1773 | int mid = db_column_int(&q, 1); |
| 1774 | if( (!g.markPrivate && content_is_private(mid)) || (mid == vid) ) continue; |
| 1775 | blob_appendf(pOut, "Q %s\n", zCherrypickUuid); |
| 1776 | } |
| 1777 | db_finalize(&q); |
| 1778 | |
| 1779 | if( p->pCksum ) blob_appendf(pOut, "R %b\n", p->pCksum); |
| 1780 | zColor = p->zColor; |
| 1781 |
+2
-3
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -1769,13 +1769,12 @@ | ||
| 1769 | 1769 | " WHERE (vmerge.id=-1 OR vmerge.id=-2)" |
| 1770 | 1770 | " ORDER BY 1"); |
| 1771 | 1771 | while( db_step(&q)==SQLITE_ROW ){ |
| 1772 | 1772 | const char *zCherrypickUuid = db_column_text(&q, 0); |
| 1773 | 1773 | int mid = db_column_int(&q, 1); |
| 1774 | - if( mid != vid ){ | |
| 1775 | - blob_appendf(pOut, "Q %s\n", zCherrypickUuid); | |
| 1776 | - } | |
| 1774 | + if( (!g.markPrivate && content_is_private(mid)) || (mid == vid) ) continue; | |
| 1775 | + blob_appendf(pOut, "Q %s\n", zCherrypickUuid); | |
| 1777 | 1776 | } |
| 1778 | 1777 | db_finalize(&q); |
| 1779 | 1778 | |
| 1780 | 1779 | if( p->pCksum ) blob_appendf(pOut, "R %b\n", p->pCksum); |
| 1781 | 1780 | zColor = p->zColor; |
| 1782 | 1781 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -1769,13 +1769,12 @@ | |
| 1769 | " WHERE (vmerge.id=-1 OR vmerge.id=-2)" |
| 1770 | " ORDER BY 1"); |
| 1771 | while( db_step(&q)==SQLITE_ROW ){ |
| 1772 | const char *zCherrypickUuid = db_column_text(&q, 0); |
| 1773 | int mid = db_column_int(&q, 1); |
| 1774 | if( mid != vid ){ |
| 1775 | blob_appendf(pOut, "Q %s\n", zCherrypickUuid); |
| 1776 | } |
| 1777 | } |
| 1778 | db_finalize(&q); |
| 1779 | |
| 1780 | if( p->pCksum ) blob_appendf(pOut, "R %b\n", p->pCksum); |
| 1781 | zColor = p->zColor; |
| 1782 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -1769,13 +1769,12 @@ | |
| 1769 | " WHERE (vmerge.id=-1 OR vmerge.id=-2)" |
| 1770 | " ORDER BY 1"); |
| 1771 | while( db_step(&q)==SQLITE_ROW ){ |
| 1772 | const char *zCherrypickUuid = db_column_text(&q, 0); |
| 1773 | int mid = db_column_int(&q, 1); |
| 1774 | if( (!g.markPrivate && content_is_private(mid)) || (mid == vid) ) continue; |
| 1775 | blob_appendf(pOut, "Q %s\n", zCherrypickUuid); |
| 1776 | } |
| 1777 | db_finalize(&q); |
| 1778 | |
| 1779 | if( p->pCksum ) blob_appendf(pOut, "R %b\n", p->pCksum); |
| 1780 | zColor = p->zColor; |
| 1781 |