Fossil

Check-in [fa760a24]
Login

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

Overview
Comment:Making annotate not segfault for the complex test case I have. There is still a little leak... but muuuch smaller than it was.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | annotate_noleak
Files: files | file ages | folders
SHA1: fa760a24cd50191313bb8f7aebf6c4d86a85eeaa
User & Date: viriketo 2011-09-04 21:02:13
Context
2011-09-04
21:39
Reducing the leak of annotate even more.

I wrote a TODO in the file, for a leak still present and relevant for files modified by many versions, but that requires harder work to get right. check-in: e2ebb1f5 user: viriketo tags: annotate_noleak

21:02
Making annotate not segfault for the complex test case I have. There is still a little leak... but muuuch smaller than it was. check-in: fa760a24 user: viriketo tags: annotate_noleak
20:43
Updating from trunk to get the latest code. check-in: 73b6ff49 user: viriketo tags: annotate_noleak
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/content.c.

93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
                             contentCache.nAlloc*sizeof(contentCache.a[0]));
  }
  p = &contentCache.a[contentCache.n++];
  p->rid = rid;
  p->age = contentCache.nextAge++;
  contentCache.szTotal += blob_size(pBlob);
  p->content = *pBlob;
  blob_reset(pBlob);
  bag_insert(&contentCache.inCache, rid);
}

/*
** Clear the content cache.
*/
void content_clear_cache(void){







|







93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
                             contentCache.nAlloc*sizeof(contentCache.a[0]));
  }
  p = &contentCache.a[contentCache.n++];
  p->rid = rid;
  p->age = contentCache.nextAge++;
  contentCache.szTotal += blob_size(pBlob);
  p->content = *pBlob;
  *pBlob = empty_blob;
  bag_insert(&contentCache.inCache, rid);
}

/*
** Clear the content cache.
*/
void content_clear_cache(void){