Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » Newbie corner » BOOST UDP issue
BOOST UDP issue [message #50427] Sat, 27 October 2018 23:20 Go to next message
defactodeepak is currently offline  defactodeepak
Messages: 2
Registered: October 2018
Location: Mohali
Junior Member
Hello,

I am writing program to use BOOST library for UDP protocol. I have occurred with an error on windows only, it is working correct on CentOS 6.9 (Linux) GCC.
Issue is - When I use send_to function to write data on socket for specific IP or Port and suppose that IP/PORT is not working, then parallel reading socket inform us that it has data available for reading. When I read that data then it has length = -1 using native socket.

Suppose for this UDP, Server PORT is 9000 and client PORT 6000, client port is not working, and forcefully send datagram packets (UDP packets) from 9000 (Server) to 6000 (client). Here, on read socket we have data and its length = -1

Here, question: why 9000 (Server) socket have data for reading just after write to socket, but during read it has -1 length.
So, if anyone have solution of this issue then please discuss.


Sample code is attached.

[Updated on: Sun, 28 October 2018 16:05]

Report message to a moderator

Re: BOOST UDP issue [message #50429 is a reply to message #50427] Sun, 28 October 2018 23:06 Go to previous message
defactodeepak is currently offline  defactodeepak
Messages: 2
Registered: October 2018
Location: Mohali
Junior Member
Please refer following link for more detail

https://stackoverflow.com/q/53026458/10568640
Previous Topic: [Solved] Recursively loop through XML node
Next Topic: Automation Internet Explorer
Goto Forum:
  


Current Time: Tue Jan 19 08:30:37 CET 2021

Total time taken to generate the page: 0.00969 seconds