author | Linus Torvalds <torvalds@linux-foundation.org> | |
Sun, 11 Nov 2007 23:35:23 +0000 (23:35 +0000) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sat, 17 Nov 2007 06:05:33 +0000 (22:05 -0800) | ||
commit | 481f0ee60eef2c34b891e5d04b7e6e5a955eedf4 | |
tree | 457bc3bad28315bac0dac582b53995ad1adb02c1 | tree | snapshot |
parent | 78e694787cb89cd008e237b17cdc7f0fa5a15d22 | commit | diff |
Fix rev-list when showing objects involving submodules
The function mark_tree_uninteresting() assumed that the tree entries
are blob when they are not trees. This is not so. Since we do
not traverse into submodules (yet), the gitlinks should be ignored.
In general, we should try to start moving away from using the
"S_ISLNK()" like things for internal git state. It was a mistake to
just assume the numbers all were same across all systems in the first
place. This implementation converts to the "object_type", and then
uses a case statement.
Noticed by Ilari on IRC.
Test script taken from an earlier version by Dscho.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The function mark_tree_uninteresting() assumed that the tree entries
are blob when they are not trees. This is not so. Since we do
not traverse into submodules (yet), the gitlinks should be ignored.
In general, we should try to start moving away from using the
"S_ISLNK()" like things for internal git state. It was a mistake to
just assume the numbers all were same across all systems in the first
place. This implementation converts to the "object_type", and then
uses a case statement.
Noticed by Ilari on IRC.
Test script taken from an earlier version by Dscho.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-pack-objects.c | diff | blob | history | |
revision.c | diff | blob | history | |
t/t6008-rev-list-submodule.sh | [new file with mode: 0755] | blob |
tree-walk.h | diff | blob | history |