read system call hangs

J

Jaydeep Chovatia

Hi,

I am using "read" system call in my C++ project to read data from sockets. I have also set read timeout (SO_RCVTIMEO) to 5 seconds using "setsockopt",but when I run my application under load run then sometimes this "read" system call hangs, it neither returns data nor it times out.

Any suggestion/help would be appreciated.

Thank you,
Jaydeep
 
I

Ian Collins

Hi,

I am using "read" system call in my C++ project to read data from sockets. I have also set read timeout (SO_RCVTIMEO) to 5 seconds using "setsockopt", but when I run my application under load run then sometimes this "read" system call hangs, it neither returns data nor it times out.

Any suggestion/help would be appreciated.

The best one I can offer here to to post to comp.unix.programmer where
socket programming is topical.
 
J

Jorgen Grahn

Hi,

I am using "read" system call in my C++ project to read data from sockets. [...]

Any suggestion/help would be appreciated.

The best one I can offer here to to post to comp.unix.programmer where
socket programming is topical.

Or comp.protocols.tcp-ip which deals with (among other things)
socket programming no matter what the OS is.

/Jorgen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,074
Latest member
StanleyFra

Latest Threads

Top