channel = (SilcChannelEntry)id_cache->context;
/* Add client to channel */
- chu = silc_calloc(1, sizeof(*chu));
- chu->client = client_entry;
- silc_list_add(channel->clients, chu);
+ if (client_entry != conn->local_entry) {
+ chu = silc_calloc(1, sizeof(*chu));
+ chu->client = client_entry;
+ silc_list_add(channel->clients, chu);
+ }
/* XXX add support for multiple same nicks on same channel. Check
for them here */
} else {
/* Yes, we have it already */
client_entry = (SilcClientEntry)id_cache->context;
- if (client_entry == conn->local_entry)
- continue;
}
/* Join the client to the channel */