On Mon, Jun 07, 2010 at 12:43:19PM -0000, dan...@apache.org wrote: > Author: dannas > Date: Mon Jun 7 12:43:19 2010 > New Revision: 952205 > > URL: http://svn.apache.org/viewvc?rev=952205&view=rev > Log: > Use several smaller functions for printing git diff headers instead of one. > > * subversion/libsvn_client/diff.c > (print_git_diff_header): Split this one into ... > (print_git_diff_header_added): ..this ... > (print_git_diff_header_deleted): .. and this ... > (print_git_diff_header_copied): .. and this ... > (print_git_diff_header_moved): .. and this ... > (print_git_diff_header_modified): .. and this. > (diff_content_changed): Adjust caller.
> @@ -681,42 +705,43 @@ diff_content_changed(const char *path, > + SVN_ERR(print_git_diff_header_deleted( > + os, > + diff_cmd_baton->header_encoding, > + path, subpool)); > + > label1 = diff_label(apr_psprintf(subpool, "a/%s", path1), rev1, > subpool); > label2 = diff_label("/dev/null", rev2, subpool); You could make the print_git_diff_headet_* functions return the appropriate labels as output parameters. E.g: SVN_ERR(print_git_diff_header_deleted( &label1, &label2, os, diff_cmd_baton->header_encoding, path, subpool)); Stefan