MCPcopy Create free account
hub / github.com/Entware/Entware / append_string

Function append_string

scripts/config/lexer.lex.c:2311–2323  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2309}
2310
2311static void append_string(const char *str, int size)
2312{
2313 int new_size = text_size + size + 1;
2314 if (new_size > text_asize) {
2315 new_size += START_STRSIZE - 1;
2316 new_size &= -START_STRSIZE;
2317 text = xrealloc(text, new_size);
2318 text_asize = new_size;
2319 }
2320 memcpy(text + text_size, str, size);
2321 text_size += size;
2322 text[text_size] = 0;
2323}
2324
2325static void alloc_string(const char *str, int size)
2326{

Callers 3

lexer.lex.cFile · 0.85
expand_tokenFunction · 0.85
append_expanded_stringFunction · 0.85

Calls 1

xreallocFunction · 0.85

Tested by

no test coverage detected