ClusterLabs/pacemaker — pull request #406 by davidvossel (2014-01-07 20:11:36+00:00)
Title: Fix: ipc: fix memory leak for failed ipc client connections.

When pacemaker ipc servers accept client connections, client
state data is allocated when the libqb 'accept' callback function is
invoked. It is possible however that even after the client
accepts the connection in the libqb 'accept' callback, the connection
could still fail to initialize fully if the client side hangs up.

Currently this results in the client state data never being
destroyed because the libqb "close" callback for client connection
is never invoked on the server side. Instead, libqb jumps directly to
the "destroy" callback because the connection never actually got created.

To account for this memory leak, pacemaker needs to verify client
state data is destroyed in the destroy callback.