Fossil SCM
Add comments for auxiliary local variables inside <code>ticket_output_change_artifact()</code>.
Commit
53b66cf63f868ac31215fa5c7aa06f8fa7b7f9c59dce3f5b42c55fe56b7f1cfb
Parent
141793c4abf9956…
1 file changed
+5
-2
+5
-2
| --- src/tkt.c | ||
| +++ src/tkt.c | ||
| @@ -1252,11 +1252,11 @@ | ||
| 1252 | 1252 | ** not have knowledge of the encoding. If the "raw" query parameter |
| 1253 | 1253 | ** is present, then the undecoded and unformatted text of each artifact |
| 1254 | 1254 | ** is displayed. |
| 1255 | 1255 | ** |
| 1256 | 1256 | ** Reassignments of a field of the TICKET table that has a corresponding |
| 1257 | -** "baseline for ..." companion are rendered as unified delta. | |
| 1257 | +** "baseline for ..." companion are rendered as unified diffs. | |
| 1258 | 1258 | */ |
| 1259 | 1259 | void tkthistory_page(void){ |
| 1260 | 1260 | Stmt q; |
| 1261 | 1261 | char *zTitle; |
| 1262 | 1262 | const char *zUuid; |
| @@ -1401,12 +1401,15 @@ | ||
| 1401 | 1401 | const char *zX = z[0]=='+' ? z+1 : z; |
| 1402 | 1402 | const int id = fieldId(zX); |
| 1403 | 1403 | const char *zValue = pTkt->aField[i].zValue; |
| 1404 | 1404 | const size_t nValue = strlen(zValue); |
| 1405 | 1405 | const int bLong = nValue>50 || memchr(zValue,'\n',nValue)!=NULL; |
| 1406 | + /* zValue is long enough to justify a <blockquote> */ | |
| 1406 | 1407 | const int bCanDiff = aLastVal && id>=0 && aField[id].zBsln; |
| 1407 | - int bAppend = 0, bRegular = 0; | |
| 1408 | + /* preliminary flag for rendering via unified diff */ | |
| 1409 | + int bAppend = 0; /* zValue is being appended to a TICKET's field */ | |
| 1410 | + int bRegular = 0; /* prev value of a TICKET's field is being superseded*/ | |
| 1408 | 1411 | @ <li>\ |
| 1409 | 1412 | if( id<0 ){ |
| 1410 | 1413 | @ Untracked field %h(zX): |
| 1411 | 1414 | }else if( aField[id].mUsed==USEDBY_TICKETCHNG ){ |
| 1412 | 1415 | @ %h(zX): |
| 1413 | 1416 |
| --- src/tkt.c | |
| +++ src/tkt.c | |
| @@ -1252,11 +1252,11 @@ | |
| 1252 | ** not have knowledge of the encoding. If the "raw" query parameter |
| 1253 | ** is present, then the undecoded and unformatted text of each artifact |
| 1254 | ** is displayed. |
| 1255 | ** |
| 1256 | ** Reassignments of a field of the TICKET table that has a corresponding |
| 1257 | ** "baseline for ..." companion are rendered as unified delta. |
| 1258 | */ |
| 1259 | void tkthistory_page(void){ |
| 1260 | Stmt q; |
| 1261 | char *zTitle; |
| 1262 | const char *zUuid; |
| @@ -1401,12 +1401,15 @@ | |
| 1401 | const char *zX = z[0]=='+' ? z+1 : z; |
| 1402 | const int id = fieldId(zX); |
| 1403 | const char *zValue = pTkt->aField[i].zValue; |
| 1404 | const size_t nValue = strlen(zValue); |
| 1405 | const int bLong = nValue>50 || memchr(zValue,'\n',nValue)!=NULL; |
| 1406 | const int bCanDiff = aLastVal && id>=0 && aField[id].zBsln; |
| 1407 | int bAppend = 0, bRegular = 0; |
| 1408 | @ <li>\ |
| 1409 | if( id<0 ){ |
| 1410 | @ Untracked field %h(zX): |
| 1411 | }else if( aField[id].mUsed==USEDBY_TICKETCHNG ){ |
| 1412 | @ %h(zX): |
| 1413 |
| --- src/tkt.c | |
| +++ src/tkt.c | |
| @@ -1252,11 +1252,11 @@ | |
| 1252 | ** not have knowledge of the encoding. If the "raw" query parameter |
| 1253 | ** is present, then the undecoded and unformatted text of each artifact |
| 1254 | ** is displayed. |
| 1255 | ** |
| 1256 | ** Reassignments of a field of the TICKET table that has a corresponding |
| 1257 | ** "baseline for ..." companion are rendered as unified diffs. |
| 1258 | */ |
| 1259 | void tkthistory_page(void){ |
| 1260 | Stmt q; |
| 1261 | char *zTitle; |
| 1262 | const char *zUuid; |
| @@ -1401,12 +1401,15 @@ | |
| 1401 | const char *zX = z[0]=='+' ? z+1 : z; |
| 1402 | const int id = fieldId(zX); |
| 1403 | const char *zValue = pTkt->aField[i].zValue; |
| 1404 | const size_t nValue = strlen(zValue); |
| 1405 | const int bLong = nValue>50 || memchr(zValue,'\n',nValue)!=NULL; |
| 1406 | /* zValue is long enough to justify a <blockquote> */ |
| 1407 | const int bCanDiff = aLastVal && id>=0 && aField[id].zBsln; |
| 1408 | /* preliminary flag for rendering via unified diff */ |
| 1409 | int bAppend = 0; /* zValue is being appended to a TICKET's field */ |
| 1410 | int bRegular = 0; /* prev value of a TICKET's field is being superseded*/ |
| 1411 | @ <li>\ |
| 1412 | if( id<0 ){ |
| 1413 | @ Untracked field %h(zX): |
| 1414 | }else if( aField[id].mUsed==USEDBY_TICKETCHNG ){ |
| 1415 | @ %h(zX): |
| 1416 |