Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrocky-luo <rocky-luo@outlook.com>2014-02-09 17:08:42 +0400
committerrocky-luo <rocky-luo@outlook.com>2014-02-09 17:08:42 +0400
commit8086b78be05dbcffc80e8a87c15fc10bb7534547 (patch)
tree5ab9a2ed13735b7d5b0777a77d0bfb4e707fd0c8 /examples
parent4f5a3f400be638de28fb7cc5d926cc79125d52f7 (diff)
replace 'out' with 'patch',replace the literal tabs with '\t'.
Diffstat (limited to 'examples')
-rw-r--r--examples/diff.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/examples/diff.c b/examples/diff.c
index 0a9b06453..abb9b7103 100644
--- a/examples/diff.c
+++ b/examples/diff.c
@@ -267,7 +267,7 @@ static void parse_opts(struct opts *o, int argc, char *argv[])
/** Display diff output with "--numstat".*/
static void diff_print_numstat(git_diff *diff)
{
- git_patch *out;
+ git_patch *patch;
const git_diff_delta *delta;
size_t i;
size_t ndeltas;
@@ -275,13 +275,13 @@ static void diff_print_numstat(git_diff *diff)
ndeltas = git_diff_num_deltas(diff);
for (i = 0; i < ndeltas; i++){
check_lg2(
- git_patch_from_diff(&out, diff, i),
+ git_patch_from_diff(&patch, diff, i),
"generating patch from diff", NULL);
check_lg2(
- git_patch_line_stats(NULL, &nadditions, &ndeletions, out),
+ git_patch_line_stats(NULL, &nadditions, &ndeletions, patch),
"generating the number of additions and deletions", NULL);
- delta = git_patch_get_delta(out);
- printf("%u %u %s\n", nadditions, ndeletions, delta->new_file.path);
+ delta = git_patch_get_delta(patch);
+ printf("%u\t%u\t%s\n", nadditions, ndeletions, delta->new_file.path);
}
- git_patch_free(out);
+ git_patch_free(patch);
}