| line |
true |
false |
branch |
|
43
|
0 |
5 |
while (val >= placevalue) { |
|
67
|
6 |
0 |
if (old_path && new_path && strcmp(old_path, new_path) != 0) { |
|
|
6 |
0 |
if (old_path && new_path && strcmp(old_path, new_path) != 0) { |
|
|
1 |
5 |
if (old_path && new_path && strcmp(old_path, new_path) != 0) { |
|
73
|
0 |
1 |
if ((common_dirlen = git_fs_path_common_dirlen(old_path, new_path)) && |
|
|
0 |
0 |
if ((common_dirlen = git_fs_path_common_dirlen(old_path, new_path)) && |
|
84
|
0 |
1 |
if (error < 0) |
|
87
|
5 |
0 |
adddel_path = new_path ? new_path : old_path; |
|
88
|
0 |
5 |
if (git_str_printf(out, " %s", adddel_path) < 0) |
|
93
|
0 |
5 |
if (stats->renames > 0) |
|
101
|
0 |
6 |
if (delta->flags & GIT_DIFF_FLAG_BINARY) { |
|
102
|
0 |
0 |
if (git_str_printf(out, |
|
107
|
0 |
6 |
if (git_str_printf(out, |
|
112
|
2 |
4 |
if (filestat->insertions || filestat->deletions) { |
|
|
1 |
1 |
if (filestat->insertions || filestat->deletions) { |
|
113
|
0 |
5 |
if (git_str_putc(out, ' ') < 0) |
|
116
|
5 |
0 |
if (!width) { |
|
137
|
0 |
6 |
return (git_str_oom(out) ? -1 : 0); |
|
148
|
0 |
0 |
if (delta->flags & GIT_DIFF_FLAG_BINARY) |
|
161
|
7 |
2 |
if (delta->old_file.mode != delta->new_file.mode) { |
|
162
|
5 |
2 |
if (delta->old_file.mode == 0) { |
|
166
|
2 |
0 |
else if (delta->new_file.mode == 0) { |
|
188
|
0 |
5 |
GIT_ASSERT_ARG(out); |
|
189
|
0 |
5 |
GIT_ASSERT_ARG(diff); |
|
192
|
0 |
5 |
GIT_ERROR_CHECK_ALLOC(stats); |
|
197
|
0 |
5 |
if (!stats->filestats) { |
|
205
|
6 |
5 |
for (i = 0; i < deltas && !error; ++i) { |
|
|
6 |
0 |
for (i = 0; i < deltas && !error; ++i) { |
|
210
|
0 |
6 |
if ((error = git_patch_from_diff(&patch, diff, i)) < 0) |
|
218
|
6 |
0 |
if (delta->old_file.path && strcmp(delta->old_file.path, delta->new_file.path) != 0) { |
|
|
1 |
5 |
if (delta->old_file.path && strcmp(delta->old_file.path, delta->new_file.path) != 0) { |
|
234
|
6 |
0 |
if (stats->max_name < namelen) |
|
236
|
4 |
2 |
if (stats->max_filestat < add + remove) |
|
245
|
0 |
5 |
if (error < 0) { |
|
257
|
0 |
2 |
GIT_ASSERT_ARG(stats); |
|
265
|
0 |
2 |
GIT_ASSERT_ARG(stats); |
|
273
|
0 |
2 |
GIT_ASSERT_ARG(stats); |
|
284
|
4 |
0 |
GIT_BUF_WRAP_PRIVATE(out, git_diff__stats_to_buf, stats, format, width); |
|
|
4 |
0 |
GIT_BUF_WRAP_PRIVATE(out, git_diff__stats_to_buf, stats, format, width); |
|
297
|
0 |
7 |
GIT_ASSERT_ARG(out); |
|
298
|
0 |
7 |
GIT_ASSERT_ARG(stats); |
|
300
|
0 |
7 |
if (format & GIT_DIFF_STATS_NUMBER) { |
|
301
|
0 |
0 |
for (i = 0; i < stats->files_changed; ++i) { |
|
302
|
0 |
0 |
if ((delta = git_diff_get_delta(stats->diff, i)) == NULL) |
|
307
|
0 |
0 |
if (error < 0) |
|
312
|
5 |
2 |
if (format & GIT_DIFF_STATS_FULL) { |
|
313
|
0 |
5 |
if (width > 0) { |
|
314
|
0 |
0 |
if (width > stats->max_name + stats->max_digits + 5) |
|
316
|
0 |
0 |
if (width < STATS_FULL_MIN_SCALE) |
|
319
|
0 |
5 |
if (width > stats->max_filestat) |
|
322
|
6 |
5 |
for (i = 0; i < stats->files_changed; ++i) { |
|
323
|
0 |
6 |
if ((delta = git_diff_get_delta(stats->diff, i)) == NULL) |
|
328
|
0 |
6 |
if (error < 0) |
|
333
|
2 |
5 |
if (format & GIT_DIFF_STATS_FULL || format & GIT_DIFF_STATS_SHORT) { |
|
|
2 |
0 |
if (format & GIT_DIFF_STATS_FULL || format & GIT_DIFF_STATS_SHORT) { |
|
334
|
2 |
5 |
git_str_printf( |
|
338
|
2 |
5 |
if (stats->insertions || stats->deletions == 0) |
|
|
2 |
0 |
if (stats->insertions || stats->deletions == 0) |
|
339
|
2 |
5 |
git_str_printf( |
|
343
|
5 |
2 |
if (stats->deletions || stats->insertions == 0) |
|
|
2 |
3 |
if (stats->deletions || stats->insertions == 0) |
|
344
|
2 |
2 |
git_str_printf( |
|
350
|
0 |
7 |
if (git_str_oom(out)) |
|
354
|
7 |
0 |
if (format & GIT_DIFF_STATS_INCLUDE_SUMMARY) { |
|
355
|
9 |
7 |
for (i = 0; i < stats->files_changed; ++i) { |
|
356
|
0 |
9 |
if ((delta = git_diff_get_delta(stats->diff, i)) == NULL) |
|
360
|
0 |
9 |
if (error < 0) |
|
370
|
0 |
5 |
if (stats == NULL) |