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

Function strbuf_attach

strbuf.c:96–104  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

94}
95
96void strbuf_attach(struct strbuf *sb, void *buf, size_t len, size_t alloc)
97{
98 strbuf_release(sb);
99 sb->buf = buf;
100 sb->len = len;
101 sb->alloc = alloc;
102 strbuf_grow(sb, 0);
103 sb->buf[sb->len] = '\0';
104}
105
106void strbuf_grow(struct strbuf *sb, size_t extra)
107{

Callers 15

enter_repoFunction · 0.85
read_oid_strbufFunction · 0.85
fake_working_tree_commitFunction · 0.85
object_file_to_archiveFunction · 0.85
replace_encoding_headerFunction · 0.85
strbuf_reencodeFunction · 0.85
handle_cacheFunction · 0.85
convert_to_utf8Function · 0.85
encode_to_gitFunction · 0.85
encode_to_worktreeFunction · 0.85
image_prepareFunction · 0.85

Calls 2

strbuf_releaseFunction · 0.85
strbuf_growFunction · 0.85

Tested by

no test coverage detected