I'm trying to create a simple "chatroom" program with C on Unix, using RPC.
Currently, multiple clients can connect to a server and call on functions generated by RPCGEN. The server receives arguments and responds with a return value. The relationship is always between client and server.
How can I use RPC to have my server send a message received from one client to another?
As per John Bollinger's very helpful last comment: "(...) the server can relay messages only via its responses to RPC calls by clients. (...)"
So basically no, clients cannot communicate directly with other clients. They can send and ask for information through a call to the server, and it is through those requests that it is possible to "communicate" from one client to the other.