MCPcopy Index your code
hub / github.com/git/git / patch_stats

Function patch_stats

apply.c:4407–4427  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4405}
4406
4407static void patch_stats(struct apply_state *state, struct patch *patch)
4408{
4409 int lines = patch->lines_added + patch->lines_deleted;
4410
4411 if (lines > state->max_change)
4412 state->max_change = lines;
4413 if (patch->old_name) {
4414 int len = quote_c_style(patch->old_name, NULL, NULL, 0);
4415 if (!len)
4416 len = strlen(patch->old_name);
4417 if (len > state->max_len)
4418 state->max_len = len;
4419 }
4420 if (patch->new_name) {
4421 int len = quote_c_style(patch->new_name, NULL, NULL, 0);
4422 if (!len)
4423 len = strlen(patch->new_name);
4424 if (len > state->max_len)
4425 state->max_len = len;
4426 }
4427}
4428
4429static int remove_file(struct apply_state *state, struct patch *patch, int rmdir_empty)
4430{

Callers 1

apply_patchFunction · 0.85

Calls 1

quote_c_styleFunction · 0.85

Tested by

no test coverage detected