Fossil

Changes On Branch warningFixes
Login

Changes On Branch warningFixes

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

Changes In Branch warningFixes Excluding Merge-Ins

This is equivalent to a diff from 3fc62dde2c to 865b8e964f

2014-09-09
19:43
More proposed fixes to the issues pointed out by Edward Berner. ... (check-in: 7807ec4e13 user: mistachkin tags: trunk)
12:43
Fix incremental builds using mingw on Windows ... (Closed-Leaf check-in: e1fa9e8889 user: baruch tags: better-mingw)
07:44
Make server on Windows aware of current checkout if run interavtivly from open checkout. Allows using special names prev/next/current in ui ... (Closed-Leaf check-in: aead49f36a user: baruch tags: baruch-winserver)
06:54
Allow shunning/unshunning multiple files at a time ... (check-in: 9f6b1964fb user: baruch tags: baruch-multishun)
2014-09-08
18:46
Another warning fix. ... (Closed-Leaf check-in: 865b8e964f user: mistachkin tags: warningFixes)
16:46
Add 'reinitialize' command to TH1. Add 'flags' to the globalState TH1 command. ... (Closed-Leaf check-in: f3a7da44df user: mistachkin tags: th1ReInit)
08:08
Highly experimental changes to enable TH1 usage in embedded docs. Do not merge. ... (check-in: 5ce57f21bd user: mistachkin tags: dynamicTh1Docs)
2014-09-07
19:50
More proposed fixes to the issues pointed out by Edward Berner. ... (check-in: 4429a4c3cc user: mistachkin tags: warningFixes)
09:49
removed a duplicated if() block, moved a free()-after-return, both reported by Edward Berner. ... (check-in: 3fc62dde2c user: stephan tags: trunk)
08:52
When using $EDITOR to enter a commit message, tags provided via the --tag flag are now listed, per ML request. ... (check-in: ae00c63109 user: stephan tags: trunk)

Changes to src/cgi.c.
1594
1595
1596
1597
1598
1599
1600
1601

1602
1603
1604
1605


1606
1607
1608
1609
1610
1611
1612
1594
1595
1596
1597
1598
1599
1600

1601

1602


1603
1604
1605
1606
1607
1608
1609
1610
1611







-
+
-

-
-
+
+







** and subsequent code handles the actual generation of the webpage.
*/
void cgi_handle_scgi_request(void){
  char *zHdr;
  char *zToFree;
  int nHdr = 0;
  int nRead;
  int n, m;
  int c, n, m;
  char c;

  while( (c = fgetc(g.httpIn))!=EOF && fossil_isdigit(c) ){
    nHdr = nHdr*10 + c - '0';
  while( (c = fgetc(g.httpIn))!=EOF && fossil_isdigit((char)c) ){
    nHdr = nHdr*10 + (char)c - '0';
  }
  if( nHdr<16 ) malformed_request("SCGI header too short");
  zToFree = zHdr = fossil_malloc(nHdr);
  nRead = (int)fread(zHdr, 1, nHdr, g.httpIn);
  if( nRead<nHdr ) malformed_request("cannot read entire SCGI header");
  nHdr = nRead;
  while( nHdr ){
Changes to src/diff.c.
592
593
594
595
596
597
598
599

600
601
602
603
604
605
606
592
593
594
595
596
597
598

599
600
601
602
603
604
605
606







-
+







static void sbsWriteColumn(Blob *pOut, Blob *pCol, int col){
  blob_appendf(pOut,
    "<td><div class=\"diff%scol\">\n"
    "<pre>\n"
    "%s"
    "</pre>\n"
    "</div></td>\n",
    col % 3 ? (col == SBS_MKR ? "mkr" : "txt") : "ln",
    (col % 3) ? (col == SBS_MKR ? "mkr" : "txt") : "ln",
    blob_str(pCol)
  );
}

/*
** Append a separator line to column iCol
*/
Changes to src/diffcmd.c.
26
27
28
29
30
31
32





33
34
35
36
37
38
39
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44







+
+
+
+
+







*/
#if defined(_WIN32)
#  define NULL_DEVICE "NUL"
#else
#  define NULL_DEVICE "/dev/null"
#endif

/*
** Used when the name for the diff is unknown.
*/
#define DIFF_NO_NAME  "(unknown)"

/*
** Print the "Index:" message that patches wants to see at the top of a diff.
*/
void diff_print_index(const char *zFile, u64 diffFlags){
  if( (diffFlags & (DIFF_SIDEBYSIDE|DIFF_BRIEF))==0 ){
    char *z = mprintf("Index: %s\n%.66c\n", zFile, '=');
    fossil_print("%s", z);
487
488
489
490
491
492
493
494








495
496
497
498
499
500
501
492
493
494
495
496
497
498

499
500
501
502
503
504
505
506
507
508
509
510
511
512
513







-
+
+
+
+
+
+
+
+







  const char *zBinGlob,
  int fIncludeBinary,
  u64 diffFlags
){
  Blob f1, f2;
  int isBin1, isBin2;
  int rid;
  const char *zName =  pFrom ? pFrom->zName : pTo->zName;
  const char *zName;
  if( pFrom ){
    zName = pFrom->zName;
  }else if( pTo ){
    zName = pTo->zName;
  }else{
    zName = DIFF_NO_NAME;
  }
  if( diffFlags & DIFF_BRIEF ) return;
  diff_print_index(zName, diffFlags);
  if( pFrom ){
    rid = uuid_to_rid(pFrom->zUuid, 0);
    content_get(rid, &f1);
  }else{
    blob_zero(&f1);
Changes to src/markdown.c.
388
389
390
391
392
393
394
395

396
397
398
399
400
401
402
388
389
390
391
392
393
394

395
396
397
398
399
400
401
402







-
+







    j = i;
    while( i<size
     && data[i]!='>'
     && data[i]!='\''
     && data[i]!='"'
     && data[i]!=' '
     && data[i]!='\t'
     && data[i]!='\t'
     && data[i]!='\n'
    ){
      i++;
    }
    if( i>=size ) return 0;
    if( i>j && data[i]=='>' ) return i+1;
    /* one of the forbidden chars has been found */
    *autolink = MKDA_NOT_AUTOLINK;
Changes to src/url.c.
236
237
238
239
240
241
242

243
244
245
246
247
248
249
250
251
252
253

254
255
256
257
258
259
260
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262







+











+







    zFile = mprintf("%s", zUrl);
  }else if( file_isdir(zUrl)==1 ){
    zFile = mprintf("%s/FOSSIL", zUrl);
    if( file_isfile(zFile) ){
      pUrlData->isFile = 1;
    }else{
      free(zFile);
      zFile = 0;
      fossil_fatal("unknown repository: %s", zUrl);
    }
  }else{
    fossil_fatal("unknown repository: %s", zUrl);
  }
  if( urlFlags ) pUrlData->flags = urlFlags;
  if( pUrlData->isFile ){
    Blob cfile;
    dehttpize(zFile);
    file_canonical_name(zFile, &cfile, 0);
    free(zFile);
    zFile = 0;
    pUrlData->protocol = "file";
    pUrlData->path = "";
    pUrlData->name = mprintf("%b", &cfile);
    pUrlData->canonical = mprintf("file://%T", pUrlData->name);
    blob_reset(&cfile);
  }else if( pUrlData->user!=0 && pUrlData->passwd==0 && (urlFlags & URL_PROMPT_PW) ){
    url_prompt_for_password_local(pUrlData);