<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/git.git/combine-diff.c, branch v1.8.3.3</title>
<subtitle>Git
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/git.git/atom?h=v1.8.3.3</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/atom?h=v1.8.3.3'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/'/>
<updated>2013-07-03T22:30:59Z</updated>
<entry>
<title>Merge branch 'cb/log-follow-with-combined' into maint</title>
<updated>2013-07-03T22:30:59Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-07-03T22:30:59Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=318e758f327c486a606ece48c5dfb5fa6e5d39d5'/>
<id>urn:sha1:318e758f327c486a606ece48c5dfb5fa6e5d39d5</id>
<content type='text'>
"git log -c --follow $path" segfaulted upon hitting the commit that
renamed the $path being followed.

* cb/log-follow-with-combined:
  fix segfault with git log -c --follow
</content>
</entry>
<entry>
<title>Merge branch 'mk/combine-diff-context-horizon-fix' into maint</title>
<updated>2013-06-27T21:37:56Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-06-27T21:37:55Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=a0bf40ddc94d8ec57c2422b29ba82f3450211300'/>
<id>urn:sha1:a0bf40ddc94d8ec57c2422b29ba82f3450211300</id>
<content type='text'>
* mk/combine-diff-context-horizon-fix:
  combine-diff.c: Fix output when changes are exactly 3 lines apart
</content>
</entry>
<entry>
<title>fix segfault with git log -c --follow</title>
<updated>2013-05-28T18:26:24Z</updated>
<author>
<name>Clemens Buchacher</name>
<email>drizzd@aon.at</email>
</author>
<published>2013-05-27T22:49:57Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=46ec510ac088ac2669e617a4c8c35e6218dabecc'/>
<id>urn:sha1:46ec510ac088ac2669e617a4c8c35e6218dabecc</id>
<content type='text'>
In diff_tree_combined we make a copy of diffopts. In
try_to_follow_renames, called via diff_tree_sha1, we free and
re-initialize diffopts-&gt;pathspec-&gt;items. Since we did not make a deep
copy of diffopts in diff_tree_combined, the original diffopts does not
get the update. By the time we return from diff_tree_combined,
rev-&gt;diffopt-&gt;pathspec-&gt;items points to an invalid memory address. We
get a segfault next time we try to access that pathspec.

Instead, along with the copy of diffopts, make a copy pathspec-&gt;items as
well.

We would also have to make a copy of pathspec-&gt;raw to keep it consistent
with pathspec-&gt;items, but nobody seems to rely on that.

Signed-off-by: Clemens Buchacher &lt;drizzd@aon.at&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>combine-diff.c: Fix output when changes are exactly 3 lines apart</title>
<updated>2013-05-15T19:02:04Z</updated>
<author>
<name>Matthijs Kooijman</name>
<email>matthijs@stdin.nl</email>
</author>
<published>2013-05-15T17:42:14Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=aac385717a62bfa6889151d191e08b9725587912'/>
<id>urn:sha1:aac385717a62bfa6889151d191e08b9725587912</id>
<content type='text'>
When a deletion is followed by exactly 3 (or whatever the number of
context lines) unchanged lines, followed by another change, the combined
diff output would hide the first deletion, resulting in a malformed
diff.

This happened because the 3 lines before each change are painted
interesting, but also marked as no_pre_delete to prevent showing deletes
that were previously marked as uninteresting. This behaviour was
introduced in c86fbe53 (diff -c/--cc: do not include uninteresting
deletion before leading context). However, as a side effect, this could
also mark deletes that were already interesting as no_pre_delete. This
would happen only if the delete was exactly 3 lines away from the next
change, since lines farther away would not be touched by the "paint
three lines before the change" code and lines closer would be painted
by the "merge two adjacent hunks" code instead, which does not set the
no_pre_delete flag.

This commit fixes this problem by only setting the no_pre_delete flag
for changes that were previously uninteresting.

Signed-off-by: Matthijs Kooijman &lt;matthijs@stdin.nl&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>combine-diff: coalesce lost lines optimally</title>
<updated>2013-03-25T21:52:33Z</updated>
<author>
<name>Antoine Pelisse</name>
<email>apelisse@gmail.com</email>
</author>
<published>2013-03-23T17:23:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=99d3206010ba1fcc9311cbe8376c0b5e78f4a136'/>
<id>urn:sha1:99d3206010ba1fcc9311cbe8376c0b5e78f4a136</id>
<content type='text'>
This replaces the greedy implementation to coalesce lost lines by using
dynamic programming to find the Longest Common Subsequence.

The O(n²) time complexity is obviously bigger than previous
implementation but it can produce shorter diff results (and most likely
easier to read).

List of lost lines is now doubly-linked because we reverse-read it when
reading the direction matrix.

Signed-off-by: Antoine Pelisse &lt;apelisse@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Allow combined diff to ignore white-spaces</title>
<updated>2013-03-14T21:43:34Z</updated>
<author>
<name>Antoine Pelisse</name>
<email>apelisse@gmail.com</email>
</author>
<published>2013-03-14T21:03:14Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=fa04ae0be8cca1291a60bc8a393f9c52d2582089'/>
<id>urn:sha1:fa04ae0be8cca1291a60bc8a393f9c52d2582089</id>
<content type='text'>
The combined diff --cc output does not honor options to ignore
whitespace changes (-b, -w, and --ignore-space-at-eol).

Correct this by passing diff flags to diff engine, so that combined
diff behaves as normal diff does with spaces, and by coalescing
lines that are removed from both (or more) parents, honoring the
same rule to ignore whitespace changes.

With this change, a conflict-less merge done using a ignore-*
strategy option will not show any conflict if shown in combined-diff
using the same option.

Signed-off-by: Antoine Pelisse &lt;apelisse@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/diff-graph-cleanup'</title>
<updated>2013-02-14T18:29:59Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-02-14T18:29:59Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=a1d68bea891118bdaecb6dd77610e6daf2f7d53d'/>
<id>urn:sha1:a1d68bea891118bdaecb6dd77610e6daf2f7d53d</id>
<content type='text'>
Refactors a lot of repetitive code sequence from the graph drawing
code and adds it to the combined diff output.

* jk/diff-graph-cleanup:
  combine-diff.c: teach combined diffs about line prefix
  diff.c: use diff_line_prefix() where applicable
  diff: add diff_line_prefix function
  diff.c: make constant string arguments const
  diff: write prefix to the correct file
  graph: output padding for merge subsequent parents
</content>
</entry>
<entry>
<title>combine-diff.c: teach combined diffs about line prefix</title>
<updated>2013-02-12T19:42:07Z</updated>
<author>
<name>John Keeping</name>
<email>john@keeping.me.uk</email>
</author>
<published>2013-02-07T20:15:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=41ee2ad6cbebab0429248a14ec4e02afddd60dbe'/>
<id>urn:sha1:41ee2ad6cbebab0429248a14ec4e02afddd60dbe</id>
<content type='text'>
When running "git log --graph --cc -p" the diff output for merges is not
indented by the graph structure, unlike the diffs of non-merge commits
(added in commit 7be5761 - diff.c: Output the text graph padding before
each diff line).

Fix this by teaching the combined diff code to output diff_line_prefix()
before each line.

Signed-off-by: John Keeping &lt;john@keeping.me.uk&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>combine-diff: lift 32-way limit of combined diff</title>
<updated>2013-02-03T21:08:18Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-02-03T21:08:18Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=776670519823b5c49ff4107dc9f77706fa37bb76'/>
<id>urn:sha1:776670519823b5c49ff4107dc9f77706fa37bb76</id>
<content type='text'>
The "raw" format of combine-diff output is supposed to have as many
colons as there are parents at the beginning, then blob modes for
these parents, and then object names for these parents.

We weren't however prepared to handle a more than 32-way merge and
did not show the correct number of colons in such a case.

Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/maint-null-in-trees' into maint-1.7.11</title>
<updated>2012-09-10T22:24:54Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2012-09-10T22:24:53Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=03adeeaad6c039aadda074de9509f4d845739d55'/>
<id>urn:sha1:03adeeaad6c039aadda074de9509f4d845739d55</id>
<content type='text'>
"git diff" had a confusion between taking data from a path in the
working tree and taking data from an object that happens to have
name 0{40} recorded in a tree.

* jk/maint-null-in-trees:
  fsck: detect null sha1 in tree entries
  do not write null sha1s to on-disk index
  diff: do not use null sha1 as a sentinel value
</content>
</entry>
</feed>
