C
Chris
Hi, I'm using CGI with MS IIS and Visual Studio 2003.
My problem is when I'm trying to read post data, I use
cin.get(buffer, size), where buffer is a new char[size + 1] and size
is the atoi of getenv("CONTENT_LENGTH").
My problem is, it cuts off one character at the end. And if I use
cin.get(buffer, size + 1), it just sits there waiting for more data.
Do I have to roll my own solution, or use fread? Is there some way to
use cin.get work for me, without having to call it twice (the second
time calling cin.get(buffer[size-1])?
My problem is when I'm trying to read post data, I use
cin.get(buffer, size), where buffer is a new char[size + 1] and size
is the atoi of getenv("CONTENT_LENGTH").
My problem is, it cuts off one character at the end. And if I use
cin.get(buffer, size + 1), it just sits there waiting for more data.
Do I have to roll my own solution, or use fread? Is there some way to
use cin.get work for me, without having to call it twice (the second
time calling cin.get(buffer[size-1])?