server/red_worker: use red_channel_destroy

This commit is contained in:
Alon Levy 2010-11-09 15:28:11 +02:00
parent 966201c1ad
commit 9e46945a61

View File

@ -7265,8 +7265,7 @@ static inline void red_unref_channel(RedChannel *channel)
ASSERT(channel);
common = SPICE_CONTAINEROF(channel, CommonChannel, base);
if (!--common->listener.refs) {
spice_marshaller_destroy(channel->send_data.marshaller);
free(channel);
red_channel_destroy(channel);
}
}