GNOME Bugzilla – Bug 111145
Pan crashes when reading .newsrc file
Last modified: 2006-06-18 05:11:22 UTC
I can reproduce SEGFAULT crash in server_is_valid(). It's caused by groups_get_subscribed() function in base/group.c, where Server * server; is declared and then later if (server != NULL) server_save_grouplist_if_dirty (server, NULL); server have value 0x3 here, which causes crash in g_return_val_if_fail (is_nonempty_string (server->name), FALSE); in server_is_valid() in base/server.c. This only happens when I'm compiling Pan with CFLAGS -march=pentiumpro, it does not happen when I omit -march switch. This haven't happened on 5.0-RELEASE (gcc 3.2.1), it does on -CURRENT with gcc 3.2.2. I'll check with FreeBSD people in case it's compiler bug. Fix: declare server as NULL in groups_get_subscribed() at group.c on line 209: Group ** changed; - Server * server; + Server * server = NULL; const ServerGroupsType type = SERVER_GROUPS_SUBSCRIBED|SERVER_GROUPS_UNSUBSCRIBED;
Thanks for the patch! Fixed in CVS: http://cvs.gnome.org/bonsai/cvsview2.cgi?diff_mode=context&whitespace_mode=show&subdir=pan/pan/base&command=DIFF_FRAMESET&file=group.c&rev1=1.94&rev2=1.95&root=/cvs/gnome http://cvs.gnome.org/bonsai/cvsview2.cgi?diff_mode=context&whitespace_mode=show&subdir=pan&command=DIFF_FRAMESET&file=ANNOUNCE.html&rev1=1.129&rev2=1.130&root=/cvs/gnome