A few more points from my side to MPI_Comm_disconnect
1.) MPI_Comm_disconnect should be called from all processes in the communicator, it is a collective operation2.) You have to disconnect/ all communicators your server is connected to.
Insofar as I understand your problem: If you have connected multiple clients and the server into one intra-communicator,you first should call com-split to get a communicator without the server.
However, you still have to disconnect the old communicator (on all processes) - called "intra comm” in your example.Besides, you also should disconnect all inter-communicator(s) created with MPI_Comm_connect and MPI_Comm_accept.
Lena