MCPcopy Create free account
hub / github.com/GJDuck/e9patch / exit

Function exit

examples/stdlib.c:5972–5985  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5970}
5971
5972static __attribute__((__noreturn__)) void exit(int status)
5973{
5974 if (mutex_lock(&stdio_mutex) < 0)
5975 panic("failed to lock stdio stream");
5976 for (int i = 0; i < 3; i++)
5977 {
5978 FILE *stream = stdio_stream[i];
5979 if (stream != NULL)
5980 fclose(stream);
5981 }
5982 (void)syscall(SYS_exit_group, status);
5983 while (true)
5984 asm volatile ("ud2");
5985}
5986
5987static __attribute__((__noreturn__)) void abort(void)
5988{

Callers 9

test_memsetFunction · 0.85
test_memcpyFunction · 0.85
parseOptionsFunction · 0.85
realMainFunction · 0.85
peekTokenFunction · 0.85
unexpectedTokenFunction · 0.85
expectTokenFunction · 0.85
expectToken2Function · 0.85
e9_plugin_initFunction · 0.85

Calls 2

mutex_lockFunction · 0.85
fcloseFunction · 0.85

Tested by 2

test_memsetFunction · 0.68
test_memcpyFunction · 0.68