for-each-ref: Fix sort with multiple keys
commit3b51222ceceed022f45193db19c57cf53f0164df
authorKacper Kornet <draenog@pld-linux.org>
Tue, 21 Aug 2012 07:47:26 +0000 (21 09:47 +0200)
committerJunio C Hamano <gitster@pobox.com>
Tue, 21 Aug 2012 21:42:12 +0000 (21 14:42 -0700)
treee68d79593a8252f033cf5d0ca527a6a9228cf6fb
parent912072d53a6f257fbbfd8a103e14248ae2382b6d
for-each-ref: Fix sort with multiple keys

The linked list describing sort options was not correctly set up in
opt_parse_sort. In the result, contrary to the documentation, only the
last of multiple --sort options to git-for-each-ref was taken into
account. This commit fixes it.

Signed-off-by: Kacper Kornet <draenog@pld-linux.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/for-each-ref.c
t/t6300-for-each-ref.sh