On Windows this
#include <stdio.h>
int main() {
putc('A',stdout);
putc('
',stdout);
putc('
',stdout);
}
outputs
A<CR><CR><LF>
How to write just LF char to stdout without automatic conversion to CR LF?
I need it to make simple socket stream reader to stdout.
I've tried bcc32 from CodeGear, mingw, tinycc all yield same result, changing putc to putchar, fputc, fwrite doesn't help either.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…