Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/emscripten-core/emscripten
/ char_repeat
Function
char_repeat
test/core/test_stdio_locking.c:22–27 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
20
#endif
21
22
char *char_repeat(int n, char c) {
23
char *dest = malloc(n + 1);
24
memset(dest, c, n);
25
dest[n] =
'\0'
;
26
return dest;
27
}
28
29
void thread_func() {
30
char *msg = char_repeat(100,
'a'
);
Callers
1
thread_func
Function · 0.85
Calls
2
memset
Function · 0.85
malloc
Function · 0.70
Tested by
no test coverage detected