Fix memory leak in retry_all_listeners: Coverity CID 485

This commit is contained in:
Nick Mathewson 2011-10-06 12:57:07 -04:00
parent 097ed9998b
commit b1632c3fb7

View File

@ -1988,13 +1988,13 @@ retry_all_listeners(smartlist_t *replaced_conns,
options->ControlListenAddress,
options->ControlPort, "127.0.0.1",
new_conns, 0) < 0)
return -1;
retval = -1;
if (retry_listeners(listeners,
CONN_TYPE_CONTROL_LISTENER,
options->ControlSocket,
options->ControlSocket ? 1 : 0, NULL,
new_conns, 1) < 0)
return -1;
retval = -1;
/* Any members that were still in 'listeners' don't correspond to
* any configured port. Kill 'em. */