OLD | NEW |
| (Empty) |
1 //========================================== | |
2 // LIBCTINY - Matt Pietrek 2001 | |
3 // MSDN Magazine, January 2001 | |
4 //========================================== | |
5 #include "libctiny.h" | |
6 #include <windows.h> | |
7 #include <stdio.h> | |
8 | |
9 extern "C" int __cdecl puts(const char * s) { | |
10 DWORD cbWritten; | |
11 HANDLE hStdOut = GetStdHandle( STD_OUTPUT_HANDLE ); | |
12 | |
13 WriteFile( hStdOut, s, lstrlen(s), &cbWritten, 0 ); | |
14 WriteFile( hStdOut, "\r\n", 2, &cbWritten, 0 ); | |
15 | |
16 return (int)(cbWritten ? cbWritten : EOF); | |
17 } | |
OLD | NEW |