Using MsgSend() and MsgReply()

You don't have to use read() and write() to interact with a resource manager; you can use the path that a resource manager registers to get a connection ID (coid) that you can use with MsgSend() to send messages to the server.

This example consists of simple client and server programs that you can use as the starting point for any similar project. There are two source files: one for the server, and one for the client. Note that the server must have the PROCMGR_AID_PATHSPACE ability enabled in order to use resmgr_attach(), and PROCMGR_AID_PUBLIC_CHANNEL enabled in order to create a public channel (i.e., without _NTO_CHF_PRIVATE set). For more information, see procmgr_ability() in the QNX Neutrino C Library Reference.