Free a cluster link, but does not free the associated node of course. * This function will just make sure that the original node associated * with this link will have the 'link' field set to NULL. */
| 638 | * This function will just make sure that the original node associated |
| 639 | * with this link will have the 'link' field set to NULL. */ |
| 640 | void freeClusterLink(clusterLink *link) { |
| 641 | if (link->conn) { |
| 642 | connClose(link->conn); |
| 643 | link->conn = NULL; |
| 644 | } |
| 645 | sdsfree(link->sndbuf); |
| 646 | zfree(link->rcvbuf); |
| 647 | if (link->node) |
| 648 | link->node->link = NULL; |
| 649 | zfree(link); |
| 650 | } |
| 651 | |
| 652 | static void clusterConnAcceptHandler(connection *conn) { |
| 653 | clusterLink *link; |
no test coverage detected