wxWidgets' sample ipc

If you are using the main C++ distribution of wxWidgets, Feel free to ask any question related to wxWidgets development here. This means questions regarding to C++ and wxWidgets, not compile problems.
Post Reply
sago
Earned a small fee
Earned a small fee
Posts: 18
Joined: Tue Oct 21, 2008 7:59 am

wxWidgets' sample ipc

Post by sago » Mon Nov 10, 2008 1:23 pm

Hello!

I want to do an application client/server like the sample of the library wxWidgets on the repertory "ipc".
But I want launch the socket in a second thread that is to say one thread per client.
Could you help me please for the beginning ; I have the impression that it is necessary to modify the library (the files sckipc.h/sckipc.cpp)

TrV
Ultimate wxWidgets Guru
Ultimate wxWidgets Guru
Posts: 630
Joined: Wed Jul 04, 2007 1:12 pm

Post by TrV » Tue Nov 11, 2008 12:00 pm

You've got merely everything here : http://forums.wxwidgets.org/viewtopic.php?t=2736

User avatar
doublemax
Moderator
Moderator
Posts: 15651
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Post by doublemax » Tue Nov 11, 2008 12:45 pm

for socket related questions i also recommend reading the respective chapter in the wxWidgets book which can officially be downloaded from here:
http://www.informit.com/store/product.a ... 0131473816
(Click on 'Downloads')
Use the source, Luke!

sago
Earned a small fee
Earned a small fee
Posts: 18
Joined: Tue Oct 21, 2008 7:59 am

Post by sago » Tue Nov 11, 2008 4:34 pm

In fact I have a problem "wxYield called recursively" with an application like the sample ipc.
I've seen in the book that it is "normal" and I've seen in the forums that I must launch the socket in a second thread.

So I've read the tutorial "Sockets FAQ/Tutorial" and after that I've posted this topic because I use wxTCPConnection, wxTCPServer, wxTCPClient classes and not directly wxSocket classes like in the tutorial "Sockets FAQ/Tutorial".

In accordance with this tutorial I should modifiy the library wx (the files sckipc.h/sckipc.cpp which contains the wxTCP.. classes)

Or I must use wxSocket classes instead of wxTCP classes.

PS: wxTCP classes use wxSocket classes

Post Reply