Simple chat across internet without server
-
Hello, I would want to write a small chat program allowing to communicate across the Net. But I only found classic Winsock samples with 1 server/clients, where clients need an ip address to connect with the server. Isn't it possible to have only clients (which would probably be also servers for others clients) ? (if I just have 2 executables on 2 different PCs, I cannot know the ip of the other client exe) Thanks.
-
Hello, I would want to write a small chat program allowing to communicate across the Net. But I only found classic Winsock samples with 1 server/clients, where clients need an ip address to connect with the server. Isn't it possible to have only clients (which would probably be also servers for others clients) ? (if I just have 2 executables on 2 different PCs, I cannot know the ip of the other client exe) Thanks.
-
Hello, I would want to write a small chat program allowing to communicate across the Net. But I only found classic Winsock samples with 1 server/clients, where clients need an ip address to connect with the server. Isn't it possible to have only clients (which would probably be also servers for others clients) ? (if I just have 2 executables on 2 different PCs, I cannot know the ip of the other client exe) Thanks.
jeff6 wrote:
Isn't it possible to have only clients (which would probably be also servers for others clients) ?
Yes, but then the client must be also a server, that is you should replicate (in the client) the server functionality you find in the 'classic Winsock examples'.
Veni, vidi, vici.