Git.pm: refactor command_close_bidi_pipe to use _cmd_close
commit1323dba6afad29d3cd07e9da85b947bfc2b912de
authorMichal Nazarewicz <mina86@mina86.com>
Tue, 12 Feb 2013 14:02:30 +0000 (12 15:02 +0100)
committerJunio C Hamano <gitster@pobox.com>
Tue, 12 Feb 2013 21:11:55 +0000 (12 13:11 -0800)
tree711dc4c1af11183300937094bb7d0e3c91129de2
parent8a2cc51b6ff335d8e5abf2d8f7be33412e4b9158
Git.pm: refactor command_close_bidi_pipe to use _cmd_close

The body of the loop in command_close_bidi_pipe sub is identical to
what _cmd_close sub does.

Instead of duplicating, refactor _cmd_close so that it accepts a
list of file handles to be closed, which makes it usable with
command_close_bidi_pipe.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
perl/Git.pm