Fossil

Check-in [2549a3a5]
Login

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

Overview
Comment:Print a warning during "fossil rebuild" for each Manifest which has F-cards but no R-card. This violates the documentation! Addendum: Documentation is corrected now: Originally the R-card was required but due to compaints that changed.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | lack-R
Files: files | file ages | folders
SHA1:2549a3a51b1c61734cc4e78a1dd0353b62ab31bd
User & Date: jan.nijtmans 2013-08-23 21:00:58
Original Comment: Print a warning during "fossil rebuild" for each Manifest which has F-cards but no R-card. This violates the documentation!
Context
2013-08-23
21:00
Print a warning during "fossil rebuild" for each Manifest which has F-cards but no R-card. This violates the documentation! Addendum: Documentation is corrected now: Originally the R-card was required but due to compaints that changed. Closed-Leaf check-in: 2549a3a5 user: jan.nijtmans tags: lack-R
20:58
Improved rendering of ascii-art hexadecimal for the captcha. check-in: d3940100 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/manifest.c.

97
98
99
100
101
102
103

104
105
106
107
108
109
110
...
898
899
900
901
902
903
904

905
906
907
908
909
910
911
...
932
933
934
935
936
937
938




939
940
941
942
943
944
945
  struct { 
    char *zName;           /* Name of the tag */
    char *zUuid;           /* UUID that the tag is applied to */
    char *zValue;          /* Value if the tag is really a property */
  } *aTag;              /* One for each T card */
  int nField;           /* Number of J cards */
  int nFieldAlloc;      /* Slots allocated in aField[] */

  struct { 
    char *zName;           /* Key or field name */
    char *zValue;          /* Value of the field */
  } *aField;            /* One for each J card */
};
#endif

................................................................................
    if( p->rDate<=0.0 ) SYNTAX("missing date on check-in");
    if( p->nField>0 ) SYNTAX("J-card in check-in");
    if( p->zTicketUuid ) SYNTAX("K-card in check-in");
    if( p->zWiki ) SYNTAX("W-card in check-in");
    if( p->zWikiTitle ) SYNTAX("L-card in check-in");
    if( p->zTicketUuid ) SYNTAX("K-card in check-in");
    if( p->zAttachName ) SYNTAX("A-card in check-in");

    p->type = CFTYPE_MANIFEST;
  }else if( p->nField>0 || p->zTicketUuid!=0 ){
    if( p->rDate<=0.0 ) SYNTAX("missing date on ticket");
    if( p->zWiki ) SYNTAX("W-card in ticket");
    if( p->zWikiTitle ) SYNTAX("L-card in ticket");
    if( p->nField==0 ) SYNTAX("missing J-card on ticket");
    if( p->nTag>0 ) SYNTAX("T-card in ticket");
................................................................................
    if( p->rDate<=0.0 ) SYNTAX("missing date on tag");
    if( p->nParent>0 ) SYNTAX("P-card in tag");
    if( p->zMimetype ) SYNTAX("N-card in tag");
    if( !seenZ ) SYNTAX("missing Z-card on tag");
    p->type = CFTYPE_CONTROL;
  }
  md5sum_init();




  if( !isRepeat ) g.parseCnt[p->type]++;
  return p;

manifest_syntax_error:
  if( zErr ){
    blob_appendf(pErr, "line %d: %s", lineNo, zErr);
  }else{







>







 







>







 







>
>
>
>







97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
...
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
...
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
  struct { 
    char *zName;           /* Name of the tag */
    char *zUuid;           /* UUID that the tag is applied to */
    char *zValue;          /* Value if the tag is really a property */
  } *aTag;              /* One for each T card */
  int nField;           /* Number of J cards */
  int nFieldAlloc;      /* Slots allocated in aField[] */
  int noR;
  struct { 
    char *zName;           /* Key or field name */
    char *zValue;          /* Value of the field */
  } *aField;            /* One for each J card */
};
#endif

................................................................................
    if( p->rDate<=0.0 ) SYNTAX("missing date on check-in");
    if( p->nField>0 ) SYNTAX("J-card in check-in");
    if( p->zTicketUuid ) SYNTAX("K-card in check-in");
    if( p->zWiki ) SYNTAX("W-card in check-in");
    if( p->zWikiTitle ) SYNTAX("L-card in check-in");
    if( p->zTicketUuid ) SYNTAX("K-card in check-in");
    if( p->zAttachName ) SYNTAX("A-card in check-in");
    if( !p->zRepoCksum ) p->noR=1;
    p->type = CFTYPE_MANIFEST;
  }else if( p->nField>0 || p->zTicketUuid!=0 ){
    if( p->rDate<=0.0 ) SYNTAX("missing date on ticket");
    if( p->zWiki ) SYNTAX("W-card in ticket");
    if( p->zWikiTitle ) SYNTAX("L-card in ticket");
    if( p->nField==0 ) SYNTAX("missing J-card on ticket");
    if( p->nTag>0 ) SYNTAX("T-card in ticket");
................................................................................
    if( p->rDate<=0.0 ) SYNTAX("missing date on tag");
    if( p->nParent>0 ) SYNTAX("P-card in tag");
    if( p->zMimetype ) SYNTAX("N-card in tag");
    if( !seenZ ) SYNTAX("missing Z-card on tag");
    p->type = CFTYPE_CONTROL;
  }
  md5sum_init();
  if (p->noR && p->nFile>0) {
      const char *x = db_text(0, "SELECT uuid FROM blob WHERE rid=%d", rid);
      fossil_warning("Manifest lacking R-card: %s by %s\n", x, p->zUser);
  }
  if( !isRepeat ) g.parseCnt[p->type]++;
  return p;

manifest_syntax_error:
  if( zErr ){
    blob_appendf(pErr, "line %d: %s", lineNo, zErr);
  }else{