[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: stdin in binary mode under Windows - how?
- From: "Dr. Markus Walther" <walther@...>
- Date: Tue, 09 Sep 2008 18:27:30 +0200
Hi all,
I am using a Lua 5.1. CGI script to handle HTTP POST-based file uploads
under Windows/Apache. The script reads blocks of data from stdin until
EOF, and strips multipart boundaries.
Since stdin is set to text mode, I am losing all carriage returns that
were present in the original file before upload.
Question: Is there an easy way to change stdin to binary mode under Windows?
--Markus
PS: I briefly studied Kepler sources and _if_ I didn't overlook
something, there is no provision against this problem as well.