MCPcopy Create free account
hub / github.com/git/git / graph_show_remainder

Function graph_show_remainder

graph.c:1590–1620  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1588}
1589
1590int graph_show_remainder(struct git_graph *graph)
1591{
1592 struct strbuf msgbuf = STRBUF_INIT;
1593 int shown = 0;
1594
1595 graph_show_line_prefix(default_diffopt);
1596
1597 if (!graph)
1598 return 0;
1599
1600 if (graph_is_commit_finished(graph))
1601 return 0;
1602
1603 for (;;) {
1604 graph_next_line(graph, &msgbuf);
1605 fwrite(msgbuf.buf, sizeof(char), msgbuf.len,
1606 graph->revs->diffopt.file);
1607 strbuf_setlen(&msgbuf, 0);
1608 shown = 1;
1609
1610 if (!graph_is_commit_finished(graph)) {
1611 putc('\n', graph->revs->diffopt.file);
1612 graph_show_line_prefix(&graph->revs->diffopt);
1613 } else {
1614 break;
1615 }
1616 }
1617 strbuf_release(&msgbuf);
1618
1619 return shown;
1620}
1621
1622static void graph_show_strbuf(struct git_graph *graph,
1623 FILE *file,

Callers 3

show_logFunction · 0.85
graph_show_commit_msgFunction · 0.85
show_commitFunction · 0.85

Calls 5

graph_show_line_prefixFunction · 0.85
graph_is_commit_finishedFunction · 0.85
graph_next_lineFunction · 0.85
strbuf_setlenFunction · 0.85
strbuf_releaseFunction · 0.85

Tested by

no test coverage detected