[Pidgin] #4486: pidgin/gtkblist.c: pidgin_blist_sort_method_unreg runs in an endless loop
Pidgin
trac at pidgin.im
Tue Dec 25 16:46:23 EST 2007
#4486: pidgin/gtkblist.c: pidgin_blist_sort_method_unreg runs in an endless loop
--------------------------------------------+-------------------------------
Reporter: Freakazoid | Type: defect
Status: new | Priority: minor
Component: pidgin (gtk) | Version: 2.3.1
Keywords: pidgin_blist_sort_method_unreg | Pending: 0
--------------------------------------------+-------------------------------
The function pidgin_blist_sort_method_unreg in the pidgin/gtkblist.c file
runs in an endless loop since there is a line missing:
{{{
void pidgin_blist_sort_method_unreg(const char *id){
GList *l = pidgin_blist_sort_methods;
while(l) {
struct pidgin_blist_sort_method *method = l->data;
if(!strcmp(method->id, id)) {
pidgin_blist_sort_methods =
g_list_delete_link(pidgin_blist_sort_methods, l);
g_free(method->id);
g_free(method->name);
g_free(method);
break;
}
}
pidgin_blist_update_sort_methods();
}
}}}
I fixed it by inserting
{{{
l=l->next;
}}}
The final result is:
{{{
void pidgin_blist_sort_method_unreg(const char *id){
GList *l = pidgin_blist_sort_methods;
while(l) {
struct pidgin_blist_sort_method *method = l->data;
if(!strcmp(method->id, id)) {
pidgin_blist_sort_methods =
g_list_delete_link(pidgin_blist_sort_methods, l);
g_free(method->id);
g_free(method->name);
g_free(method);
break;
}
l=l->next;
}
pidgin_blist_update_sort_methods();
}
}}}
--
Ticket URL: <http://developer.pidgin.im/ticket/4486>
Pidgin <http://pidgin.im>
Pidgin
More information about the Tracker
mailing list