LibC: Make stdio and malloc initialization constructors

This commit is contained in:
2025-04-15 22:01:57 +03:00
parent 5539d5eed0
commit 3721dadd72
3 changed files with 20 additions and 16 deletions

View File

@@ -94,7 +94,8 @@ static int drop_read_buffer(FILE* file)
return 0;
}
void _init_stdio()
__attribute__((constructor))
static void _init_stdio()
{
for (size_t i = 0; i < FOPEN_MAX; i++)
{