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

Function xstrdup

wrapper.c:41–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39}
40
41char *xstrdup(const char *str)
42{
43 char *ret = strdup(str);
44 if (!ret)
45 die("Out of memory, strdup failed");
46 return ret;
47}
48
49static void *do_xmalloc(size_t size, int gentle)
50{

Callers 15

git_config_stringFunction · 0.85
configset_add_valueFunction · 0.85
comment_char_callbackFunction · 0.85
read_worktree_configFunction · 0.85
handle_extension_v0Function · 0.85
parse_reference_uriFunction · 0.85
setup_git_env_internalFunction · 0.85
setup_explicit_git_dirFunction · 0.85

Calls 1

dieFunction · 0.70

Tested by 15

parse_refspecFunction · 0.68
refspec_item_initFunction · 0.68
refspec_find_matchFunction · 0.68
init_pathspec_itemFunction · 0.68
parse_pathspecFunction · 0.68
copy_pathspecFunction · 0.68
test_reftable_stack__addFunction · 0.68