aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/lib/stdio/vprintf.c
blob: 540530929c1f5b7eff78babb70b8338bfe75bb6c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include <lib/lib.h>
#include <lib/stdio.h>
#include <lib/stdlib.h>
#include <stdint.h>

// TODO: Use global formatting function
// TODO: Fix fixed buffer size
void vprintf(const char *fmt, va_list args)
{
	char buf[1024];
	memset(buf, 0, 1024);
	vsprintf(buf, fmt, args);

	for (u32 i = 0; i < strlen(buf); i++)
		putch(buf[i]);
}