cluster: don't send messages if no IPC channel
Checklist
-
tests and code linting passes -
the commit message follows commit guidelines
Affected core subsystem(s)
cluster
Description of change
Avoid sending messages if the IPC channel is already disconnected.
It avoids undesired errors when calling process.disconnect
when there
are still pending IPC messages.
/cc @cjihrig @bnoordhuis