my server is blocking...

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

 



Hi list,

I'm a beginner in C (sockets) programming, so please, excuse my stupid question.

I'm trying to do a servent (server+client) for a p2p connexion. When I
dissociate the client and the server, everything's all right. The
Server is waiting for (pending) a connexion and when I connect on it,
I've the behaviour I want.

But now, I tried to merge the server & client together. When I start
my program, the server is pending and the other part of my program
isn't executed :( (the server is pending in an "accept" state). I
tried to do some fork(), but it was useless (in fact, a new server is
restarted and I get a bind error). How can I solve this problem
(easily, if possible) ?

In advance, thank you for your help

norbert
-
: send the line "unsubscribe linux-c-programming" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Assembler]     [Git]     [Kernel List]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [C Programming]     [Yosemite Campsites]     [Yosemite News]     [GCC Help]

  Powered by Linux