bug-commoncpp
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

recv() && MSG_PEEK problem!


From: Qing Shen
Subject: recv() && MSG_PEEK problem!
Date: Fri, 27 Feb 2004 18:54:30 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040113

Hallo,

I recently fund a problem about recv() and MSG_PEEK which were used in ost::SocketPort::Peek(...).

I fund the problem by running "SampleSocketPort". the "peek" function can't get the right buffer size.
In my case, it always return 1 as the buffer size.

In fact it's caused by MSG_PEEK. Because it's an unreliable working method specially under Windows.

I tested it under several system. Furtunately I only find the problem under Windows 20000 professional.

further info. about MSG_PEEK problem can be fund via these links:
   http://support.microsoft.com/support/kb/articles/Q192/5/99.ASP
   http://support.microsoft.com/support/kb/articles/Q140/2/63.asp

I hope some developer can modify this demo and maybe implement it with receive() instead of peek().

Thanks,

Qing Shen

--
========================================
  Qing Shen
  Rechnerintegrierte Produktion
  Heinz Nixdorf Institut,
  Fuerstenallee 11
  33102 Paderborn, Germany
  Tel. ++49 +5251 60-6227
  Fax. ++49 +5251 60-6268
  http://wwwhni.uni-paderborn.de/vr/
========================================





reply via email to

[Prev in Thread] Current Thread [Next in Thread]