Fossil

Check-in [d30abe15]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Make sure that the UUID of a generated P-card is the UUID of a valid check-in in this repository. If not, bail out early.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:d30abe150a2ffd868bcae883a9fc466b2ad05be6
User & Date: jan.nijtmans 2013-10-09 09:20:06
Context
2013-10-09
12:06
Change "Abbreviated Name" to "Tarball and ZIP-archive Prefix" on the "Configuration" page of setup. check-in: 49e112c9 user: drh tags: trunk
09:20
Make sure that the UUID of a generated P-card is the UUID of a valid check-in in this repository. If not, bail out early. check-in: d30abe15 user: jan.nijtmans tags: trunk
08:24
Be carefull comparing a char < ' ': If the platform 'char' type is signed, this will be true for all UTF-8 characters >0x7f as well. check-in: c426475e user: jan.nijtmans tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/checkin.c.

985
986
987
988
989
990
991
992


993
994
995
996
997
998
999
1000
1001
  int nFBcard = 0;            /* Number of B-cards and F-cards */
  int i;                      /* Loop counter */
  const char *zColor;         /* Modified value of p->zColor */

  assert( pBaseline==0 || pBaseline->zBaseline==0 );
  assert( pBaseline==0 || zBaselineUuid!=0 );
  blob_zero(pOut);
  zParentUuid = db_text(0, "SELECT uuid FROM blob WHERE rid=%d", vid);


  if( !zParentUuid ){
    fossil_fatal("Could not find manifest for RID %d. "
                 "Possible checkout/repo mismatch.", vid);
  }
  if( pBaseline ){
    blob_appendf(pOut, "B %s\n", zBaselineUuid);
    manifest_file_rewind(pBaseline);
    pFile = manifest_file_next(pBaseline, 0);
    nFBcard++;







|
>
>

|







985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
  int nFBcard = 0;            /* Number of B-cards and F-cards */
  int i;                      /* Loop counter */
  const char *zColor;         /* Modified value of p->zColor */

  assert( pBaseline==0 || pBaseline->zBaseline==0 );
  assert( pBaseline==0 || zBaselineUuid!=0 );
  blob_zero(pOut);
  zParentUuid = db_text(0, "SELECT uuid FROM blob WHERE rid=%d AND "
    "EXISTS(SELECT 1 FROM event WHERE event.type='ci' and event.objid=%d)",
    vid, vid);
  if( !zParentUuid ){
    fossil_fatal("Could not find a valid check-in for RID %d. "
                 "Possible checkout/repo mismatch.", vid);
  }
  if( pBaseline ){
    blob_appendf(pOut, "B %s\n", zBaselineUuid);
    manifest_file_rewind(pBaseline);
    pFile = manifest_file_next(pBaseline, 0);
    nFBcard++;