annotate templates/filelog.tmpl @ 827:a61728b58dc0

Fix array overflow bug in bdiff I ran into a bug while importing a large repository into mercurial. The diff algorithm does not allocate a big enough array of hunks for some test cases. This results in memory corruption, and possibly, as in my case, a seg fault. You should be able to reproduce this problem with any case of more than a few lines that follows this pattern: a b = = 1 1 2 2 3 4 3 5 . 4 . . 5 . . . I.e., "a" has blank lines on every other line that have been removed in "b". In this case, the number of matching hunks is equal to the number of lines in "b". This is more than ((an + bn)/4 + 2). I'm not sure what motivates this formula, but when I changed it to the smaller of an or bn (+ 1), it works. [comment added by mpm]
author "Wallace, Eric S" <eric.s.wallace@intel.com>
date Thu, 04 Aug 2005 13:25:59 -0800
parents 148f642d1f8e
children ea67e5b37043 5197fb9d65d5 4f81068ed8cd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
142
529bf610092e Prettify the web interface
mpm@selenic.com
parents: 138
diff changeset
1 #header#
201
f918a6fa2572 hgweb: add template filters, template style maps, and raw pages
mpm@selenic.com
parents: 168
diff changeset
2 <title>#repo|escape#: #file# history</title>
661
148f642d1f8e Add rss tag in the changelog/filelog html template.
kreijack@inwind.REMOVEME.it
parents: 599
diff changeset
3 <link rel="alternate" type="application/rss+xml"
148f642d1f8e Add rss tag in the changelog/filelog html template.
kreijack@inwind.REMOVEME.it
parents: 599
diff changeset
4 href="?cmd=filelog;file=#file#;filenode=0;style=rss" title="RSS feed for #repo|escape#:#file#">
148f642d1f8e Add rss tag in the changelog/filelog html template.
kreijack@inwind.REMOVEME.it
parents: 599
diff changeset
5 </head>
142
529bf610092e Prettify the web interface
mpm@selenic.com
parents: 138
diff changeset
6 </head>
138
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
7 <body>
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
8
154
1d5f799ebe1e fixed problem with head/body tags, added dtd, fixed table attributes
jake@edge2.net
parents: 153
diff changeset
9 <div class="buttons">
138
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
10 <a href="?cmd=changelog">changelog</a>
168
65cf1b0cfe86 hgweb: add tags links and manifest links
mpm@selenic.com
parents: 155
diff changeset
11 <a href="?cmd=tags">tags</a>
153
e8a360cd5a9f changed pos to rev for changelog cmd, changed & to ;
jake@edge2.net
parents: 142
diff changeset
12 <a href="?cmd=file;file=#file#;filenode=#filenode#">file</a>
e8a360cd5a9f changed pos to rev for changelog cmd, changed & to ;
jake@edge2.net
parents: 142
diff changeset
13 <a href="?cmd=annotate;file=#file#;filenode=#filenode#">annotate</a>
661
148f642d1f8e Add rss tag in the changelog/filelog html template.
kreijack@inwind.REMOVEME.it
parents: 599
diff changeset
14 <a type="application/rss+xml" href="?cmd=filelog;file=#file#;filenode=0;style=rss">rss</a>
142
529bf610092e Prettify the web interface
mpm@selenic.com
parents: 138
diff changeset
15 </div>
138
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
16
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
17 <h2>#file# revision history</h2>
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
18
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
19 #entries#
c77a679e9cfa Revamped templated hgweb
mpm@selenic.com
parents:
diff changeset
20
142
529bf610092e Prettify the web interface
mpm@selenic.com
parents: 138
diff changeset
21 #footer#