Click here to Skip to main content
15,926,596 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Common Control Manifest File Pin
James R. Twine7-Apr-06 0:39
James R. Twine7-Apr-06 0:39 
GeneralRe: Common Control Manifest File Pin
RichardS7-Apr-06 0:50
RichardS7-Apr-06 0:50 
QuestionXp Style Explorer Bar Pin
RockyJames6-Apr-06 4:26
RockyJames6-Apr-06 4:26 
QuestionQuestion on "InitInstance" method... Pin
Siva Sankar Koyi6-Apr-06 4:16
Siva Sankar Koyi6-Apr-06 4:16 
AnswerRe: Question on "InitInstance" method... Pin
David Crow6-Apr-06 4:22
David Crow6-Apr-06 4:22 
Questionsocket question Pin
nahitan6-Apr-06 4:02
nahitan6-Apr-06 4:02 
AnswerRe: socket question Pin
Roger Stoltz6-Apr-06 4:40
Roger Stoltz6-Apr-06 4:40 
AnswerRe: socket question Pin
abbiyr6-Apr-06 5:05
abbiyr6-Apr-06 5:05 
Hi there.
                ----Client 1         
------          |
Server| --------+---Client 2
------          |
                ----Client 3

Two solutions come to mind. My assumptions
. your server is acting as a proxy - i.e. clients 1,2,3 only talk to the server, not directly to each other.
. client 1 is only ever a socket client, it does not listen for a connection
. client 2,3 have sockets open waiting for a connection from the server.

Firstly, if you want one socket listening on your server, you will have to inspect the messages.

No sign message
The steps,
. Client 1 sends message
. Server (starting a new thread for the connection) inspects message and opens a connection a connection to client 2 and sends message to client 2
. Client 2 ACKS message to Server
. Server ACKS message to Client 1

Sign on request message
. Client 1 sends message
. Server (starting a new thread for the connection) inspects message and opens a connection a connection to client 3 and sends message to client 3
. Client 3 signs and returns to the message to the server.
. Server opens a connection a connection to client 2 and sends signed message to client 2
. Client 2 ACKS message to Server
. Server ACKS message to Client 1

Alternatively, if you use two different sockets on your server, one for signed messages, one for normal messages, then you will not have to inspect the messages on the server.

Remember to use threads when accepting your socket connections.

Hope this helps concrete your design.

Cheers
GeneralRe: socket question Pin
nahitan6-Apr-06 5:37
nahitan6-Apr-06 5:37 
QuestionIcons, bmps and art for programmers Pin
HvalaMne6-Apr-06 3:28
HvalaMne6-Apr-06 3:28 
AnswerRe: Icons, bmps and art for programmers Pin
Ștefan-Mihai MOGA6-Apr-06 3:39
professionalȘtefan-Mihai MOGA6-Apr-06 3:39 
AnswerRe: Icons, bmps and art for programmers Pin
Waldermort6-Apr-06 4:15
Waldermort6-Apr-06 4:15 
AnswerRe: Icons, bmps and art for programmers Pin
David Crow6-Apr-06 4:16
David Crow6-Apr-06 4:16 
AnswerRe: Icons, bmps and art for programmers Pin
Nibu babu thomas6-Apr-06 18:06
Nibu babu thomas6-Apr-06 18:06 
GeneralRe: Icons, bmps and art for programmers Pin
toxcct6-Apr-06 21:25
toxcct6-Apr-06 21:25 
GeneralRe: Icons, bmps and art for programmers Pin
Nibu babu thomas6-Apr-06 21:27
Nibu babu thomas6-Apr-06 21:27 
GeneralRe: Icons, bmps and art for programmers Pin
toxcct6-Apr-06 21:29
toxcct6-Apr-06 21:29 
GeneralRe: Icons, bmps and art for programmers Pin
Nibu babu thomas6-Apr-06 21:49
Nibu babu thomas6-Apr-06 21:49 
GeneralRe: Icons, bmps and art for programmers Pin
toxcct6-Apr-06 21:52
toxcct6-Apr-06 21:52 
GeneralRe: Icons, bmps and art for programmers Pin
Nibu babu thomas6-Apr-06 21:56
Nibu babu thomas6-Apr-06 21:56 
GeneralRe: Icons, bmps and art for programmers Pin
toxcct6-Apr-06 21:59
toxcct6-Apr-06 21:59 
GeneralRe: Icons, bmps and art for programmers Pin
Nibu babu thomas6-Apr-06 22:01
Nibu babu thomas6-Apr-06 22:01 
GeneralRe: Icons, bmps and art for programmers Pin
HvalaMne6-Apr-06 22:13
HvalaMne6-Apr-06 22:13 
QuestionMFC ActiveX Control Pin
Identity Undisclosed6-Apr-06 2:47
Identity Undisclosed6-Apr-06 2:47 
AnswerRe: MFC ActiveX Control Pin
Cedric Moonen6-Apr-06 2:59
Cedric Moonen6-Apr-06 2:59 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.