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

Function starts_with_mem

strbuf.c:29–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27}
28
29bool starts_with_mem(const char *str, size_t len, const char *prefix)
30{
31 const char *end = str + len;
32 for (; ; str++, prefix++) {
33 if (!*prefix)
34 return true;
35 else if (str == end || *str != *prefix)
36 return false;
37 }
38}
39
40bool skip_to_optional_arg_default(const char *str, const char *prefix,
41 const char **arg, const char *def)

Callers 4

add_commented_linesFunction · 0.85
parse_insn_lineFunction · 0.85
find_trailer_block_startFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected