MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / main

Function main

test/other/test_reallocarray.c:6–21  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4#include <string.h>
5
6int main(void) {
7 char* p = calloc(4, sizeof(char));
8 assert(p);
9
10 strcpy(p, "foo");
11 puts(p);
12
13 p = reallocarray(p, 32, sizeof(char));
14 assert(p);
15
16 strcpy(p, "foobar");
17 puts(p);
18
19 free(p);
20 return 0;
21}

Callers

nothing calls this directly

Calls 6

strcpyFunction · 0.85
putsFunction · 0.85
callocFunction · 0.50
assertFunction · 0.50
reallocarrayFunction · 0.50
freeFunction · 0.50

Tested by

no test coverage detected