Rev 6429 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
6412 | siemargl | 1 | #include |
647 | andrew_pro | 2 | #include |
6429 | siemargl | 3 | #include |
6433 | siemargl | 4 | #include |
647 | andrew_pro | 5 | |
6429 | siemargl | 6 | int printf(const char *format, ...) |
647 | andrew_pro | 7 | { |
6433 | siemargl | 8 | va_list arg; |
9 | va_start(arg, format); |
||
10 | |||
11 | return vprintf(format, arg); |
||
12 | } |
||
13 | |||
14 | |||
15 | int vprintf ( const char * format, va_list arg ) |
||
16 | { |
||
6424 | siemargl | 17 | int i = 0; |
6429 | siemargl | 18 | int printed_simbols = 0; |
647 | andrew_pro | 19 | char *s; |
20 | |||
6429 | siemargl | 21 | i=con_init_console_dll(); |
647 | andrew_pro | 22 | |
6433 | siemargl | 23 | if (i == 0) |
647 | andrew_pro | 24 | { |
6433 | siemargl | 25 | s = malloc(4096); |
26 | printed_simbols = format_print(s, 4096, format, arg); |
||
6429 | siemargl | 27 | con_write_string(s, printed_simbols); |
647 | andrew_pro | 28 | free(s); |
29 | } |
||
6433 | siemargl | 30 | |
647 | andrew_pro | 31 | return(printed_simbols); |
32 | } |