s/channel_request_close()/channel_mark_for_close()/g for consistency

This commit is contained in:
Andrea Shepard 2012-10-08 20:14:04 -07:00
parent 8a41dd20cb
commit d61e58e1ba
No known key found for this signature in database
GPG Key ID: 80BF498218A1E61B
3 changed files with 9 additions and 9 deletions

View File

@ -772,7 +772,7 @@ channel_force_free(channel_t *chan)
if (chan->u.listener.incoming_list) { if (chan->u.listener.incoming_list) {
SMARTLIST_FOREACH_BEGIN(chan->u.listener.incoming_list, SMARTLIST_FOREACH_BEGIN(chan->u.listener.incoming_list,
channel_t *, qchan) { channel_t *, qchan) {
channel_request_close(qchan); channel_mark_for_close(qchan);
} SMARTLIST_FOREACH_END(qchan); } SMARTLIST_FOREACH_END(qchan);
smartlist_free(chan->u.listener.incoming_list); smartlist_free(chan->u.listener.incoming_list);
@ -965,7 +965,7 @@ channel_set_cell_handlers(channel_t *chan,
} }
/** /**
* Request a channel be closed * Mark a channel to be closed
* *
* This function tries to close a channel_t; it will go into the CLOSING * This function tries to close a channel_t; it will go into the CLOSING
* state, and eventually the lower layer should put it into the CLOSED or * state, and eventually the lower layer should put it into the CLOSED or
@ -975,7 +975,7 @@ channel_set_cell_handlers(channel_t *chan,
*/ */
void void
channel_request_close(channel_t *chan) channel_mark_for_close(channel_t *chan)
{ {
tor_assert(chan != NULL); tor_assert(chan != NULL);
tor_assert(chan->close != NULL); tor_assert(chan->close != NULL);
@ -2419,7 +2419,7 @@ channel_free_all(void)
* and allocate that again on close. * and allocate that again on close.
*/ */
channel_unregister(curr); channel_unregister(curr);
channel_request_close(curr); channel_mark_for_close(curr);
channel_force_free(curr); channel_force_free(curr);
} SMARTLIST_FOREACH_END(curr); } SMARTLIST_FOREACH_END(curr);
@ -2442,7 +2442,7 @@ channel_free_all(void)
* and allocate that again on close. * and allocate that again on close.
*/ */
channel_unregister(curr); channel_unregister(curr);
channel_request_close(curr); channel_mark_for_close(curr);
channel_force_free(curr); channel_force_free(curr);
} SMARTLIST_FOREACH_END(curr); } SMARTLIST_FOREACH_END(curr);
@ -2464,7 +2464,7 @@ channel_free_all(void)
if (!(curr->state == CHANNEL_STATE_CLOSING || if (!(curr->state == CHANNEL_STATE_CLOSING ||
curr->state == CHANNEL_STATE_CLOSED || curr->state == CHANNEL_STATE_CLOSED ||
curr->state == CHANNEL_STATE_ERROR)) { curr->state == CHANNEL_STATE_ERROR)) {
channel_request_close(curr); channel_mark_for_close(curr);
} }
channel_force_free(curr); channel_force_free(curr);
} SMARTLIST_FOREACH_END(curr); } SMARTLIST_FOREACH_END(curr);

View File

@ -230,7 +230,7 @@ const char * channel_state_to_string(channel_state_t state);
/* Abstract channel operations */ /* Abstract channel operations */
void channel_request_close(channel_t *chan); void channel_mark_for_close(channel_t *chan);
void channel_write_cell(channel_t *chan, cell_t *cell); void channel_write_cell(channel_t *chan, cell_t *cell);
void channel_write_packed_cell(channel_t *chan, packed_cell_t *cell); void channel_write_packed_cell(channel_t *chan, packed_cell_t *cell);
void channel_write_var_cell(channel_t *chan, var_cell_t *cell); void channel_write_var_cell(channel_t *chan, var_cell_t *cell);

View File

@ -224,7 +224,7 @@ channel_tls_free_all(void)
if (channel_tls_listener) { if (channel_tls_listener) {
base = TLS_CHAN_TO_BASE(channel_tls_listener); base = TLS_CHAN_TO_BASE(channel_tls_listener);
channel_unregister(base); channel_unregister(base);
channel_request_close(base); channel_mark_for_close(base);
channel_free(base); channel_free(base);
channel_tls_listener = NULL; channel_tls_listener = NULL;
} }
@ -316,7 +316,7 @@ channel_tls_close_method(channel_t *chan)
if (chan->u.listener.incoming_list) { if (chan->u.listener.incoming_list) {
SMARTLIST_FOREACH_BEGIN(chan->u.listener.incoming_list, SMARTLIST_FOREACH_BEGIN(chan->u.listener.incoming_list,
channel_t *, ichan) { channel_t *, ichan) {
channel_request_close(ichan); channel_mark_for_close(ichan);
} SMARTLIST_FOREACH_END(ichan); } SMARTLIST_FOREACH_END(ichan);
smartlist_free(chan->u.listener.incoming_list); smartlist_free(chan->u.listener.incoming_list);