socket initialization and other fixes

This commit is contained in:
Guenter Obiltschnig
2009-04-14 11:02:21 +00:00
parent 457e24748d
commit 9cb9229a4e
17 changed files with 92 additions and 49 deletions

View File

@@ -1,7 +1,7 @@
//
// MultipartReader.cpp
//
// $Id: //poco/svn/Net/src/MultipartReader.cpp#2 $
// $Id: //poco/Main/Net/src/MultipartReader.cpp#13 $
//
// Library: Net
// Package: Messages
@@ -76,7 +76,7 @@ int MultipartStreamBuf::readFromDevice(char* buffer, std::streamsize length)
int ch = _istr.get();
if (ch == eof) return -1;
*buffer++ = (char) ch; ++n;
if (ch == '\n' || ch == '\r' && _istr.peek() == '\n')
if (ch == '\n' || (ch == '\r' && _istr.peek() == '\n'))
{
if (ch == '\r')
{
@@ -102,7 +102,7 @@ int MultipartStreamBuf::readFromDevice(char* buffer, std::streamsize length)
}
if (it == end)
{
if (ch == '\n' || ch == '\r' && _istr.peek() == '\n')
if (ch == '\n' || (ch == '\r' && _istr.peek() == '\n'))
{
if (ch == '\r')
{