get_patch_filename(): split into two functions
authorJunio C Hamano <gitster@pobox.com>
Sat, 22 Dec 2012 06:06:01 +0000 (22:06 -0800)
committerJunio C Hamano <gitster@pobox.com>
Sat, 22 Dec 2012 07:55:40 +0000 (23:55 -0800)
The function switched between two operating modes depending on the
NULL-ness of its two parameters, as a hacky way to share small part
of implementation, sacrificing cleanliness of the API.

Implement "fmt_output_subject()" function that takes a subject
string and gives the name for the output file, and on top of it,
implement "fmt_output_commit()" function that takes a commit and
gives the name for the output file.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
No differences found