Re: Talking




Salvatore Di Fazio wrote:

Hi guys,
I have a little problem.

What is the problem?

I just try to make two clients (in python) that can talk together.

Okay, that is your goal.

I have made a server that gets the clients connection request and
makes a child (fork it).

I thought that to make a talking channel I needed just the list of
socket connected.

So I wrote that:
....
cout << "list_fd: "<< list_fd << endl;
cnnlist_fd[i] = conn_fd;
cout << "conn_fd: " << conn_fd << endl;
i++;
ServEcho(conn_fd); // handle echo
....

Has you can read I use an example of SerEcho to make my project.
In the ServEcho function I try to use the cnnlist_fd array to
understand where the string will be sent.

Okay, that is how you plan to achieve your goal.

Where do I make a mistake?

No idea. What's not happening that should be happening? Or where do you
get stuck?

DS

.



Relevant Pages

  • Re: Film on Spaghetti Noodles
    ... boil, break noodles, ... Okay. ... They are already cut to the correct length to eat with a fork. ...
    (rec.food.cooking)
  • Re: Film on Spaghetti Noodles
    ... boil, break noodles, ... Okay. ... They are already cut to the correct length to eat with a fork. ...
    (rec.food.cooking)
  • Re: pythonic exec* spawn*
    ... fork() is implemented strictly on a 'need to know' basis :-) ... the forked process also ends. ... Okay, thanks a lot, I'll look into that. ...
    (comp.lang.python)
  • Re: Same sex adoption in Israel
    ... holocaust survivor BTW, I learned what LIES and DECEIT liberal ... femiNazi Jews are capable of! ... Nor does it make it okay to claim that chareidi families ... crying towel for this ongoing whine about his being the child of holocaust ...
    (soc.culture.jewish.moderated)
  • Re: The Apprentice - Quantum Physisistististsss need not apply!!
    ... in the same way you might consider Alan Sugar to be. ... I fail to see what advantage you're really giving your child by ... with Tre that a bit of cutting corners with the VAT is also okay? ... Sophie had an unimpeachably good point about selling stuff you don't ...
    (uk.media.tv.misc)