unpack-trees: don't perform any index operation if we're not merging
commit97e5954bdcf46c76e4a8147172ff7c5a4f633e0d
authorRené Scharfe <rene.scharfe@lsrfire.ath.cx>
Tue, 10 Apr 2012 18:55:58 +0000 (10 20:55 +0200)
committerJunio C Hamano <gitster@pobox.com>
Tue, 10 Apr 2012 23:36:18 +0000 (10 16:36 -0700)
tree8e45d9a4bc4a60e44615fed5fdf2740fa7c9a8ab
parent69f4e08f535d4e5a035069a64d1ebaea7be55d83
unpack-trees: don't perform any index operation if we're not merging

src[0] points to the index entry in the merge case and to the first
tree to unpack in the non-merge case.  We only want to mark the index
entry, so check first if we're merging.

Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
unpack-trees.c