mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-11-04 07:45:56 +00:00
Fix issues removing autojoin channels
- Makes remove case insensitive - Fixes crashing when channel not found
This commit is contained in:
1 parent
ccf49aa48d
commit
5f297950a2
2 files changed
+6
-3
No files matched your search
@@ -842,7 +842,7 @@ servlist_favchan_find (ircnet *net, char *channel, int *pos)
|
||||
while (list)
|
||||
{
|
||||
favchan = list->data;
|
||||
if (strcmp (favchan->name, channel) == 0)
|
||||
if (g_ascii_strcasecmp (favchan->name, channel) == 0)
|
||||
{
|
||||
if (pos)
|
||||
{
|
||||
|
||||
@@ -1088,8 +1088,11 @@ servlist_autojoinedit (ircnet *net, char *channel, gboolean add)
|
||||
else
|
||||
{
|
||||
fav = servlist_favchan_find (net, channel, NULL);
|
||||
servlist_favchan_remove (net, fav);
|
||||
servlist_save ();
|
||||
if (fav)
|
||||
{
|
||||
servlist_favchan_remove (net, fav);
|
||||
servlist_save ();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user