connect() succeeds but accept() does not?


Posted on 16th Feb 2014 07:03 pm by admin

Please help me with this problem. I'm working on a time-sensitive project where I'm using TCP sockets. I've got this problem where most of the time a connection cannot be made.

While debugging, I see that the connect() call on the client succeeds but on the host machine it will just be stuck on accept (or just bypass it with EWOULDBLOCK if it was set to a non-blocking socket)

Did you know?Explore Trending and Topic pages for more stories like this.
I'm not very experienced with socket programming, so I'm not sure what can cause this behavior. Also what makes it difficult to solve is that sometimes it works perfectly fine.

What are some possible reasons for this problem to occur?
No comments posted yet

Your Answer:

Login to answer
187 Like 30 Dislike
Previous forums Next forums
Other forums

Retrieving the 25 most recently added entries from all tables in a MySQL databas
Hello,

The code below works great. It creates a table that shows the 25 most recently added t

CURL XML Request [From C to PHP]
Hi,

I need some help converting this into something that will work with PHP.

Code: #

need help modifying script
Hi guys,

I'm fairly new to php and am having a bit of trouble modifying a script.

This

Displaying Multidimensional Arrays...about to put my head in a vice, PLEASE HELP
I am fairly new to PHP and MySQL and I have a problem which I have been trying to resolve for days.

Problem with HTTP Caching...?
Hi there, im trying to implement caching. But it doesn't always work.
I post it here because ther

modifying query string with no page refresh
Hi everybody,
I've tried to get info about my problem all over the internet but i didn't find out

add text and number image
hi guys ..

ok see i want the user to add their name and pick a number then click get it and i

Recode Abap Dynpro into Web Dynpro
Hi All,
A client has asked us to look at rearchitecting a custom transaction that was developed

How many users online in the last 24-hours using time()?
I'm fairly new to PHP. I have a MySQL table called 'users' and a field called 'loggedin' which is in

Is this possible? If one file assigned to an ID...
I have a page that lists property listings assigned to a specific user (a manage page), with brief t

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash