Bug 1294318 - crash in pan::GroupPane::read_group
crash in pan::GroupPane::read_group
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: pan (Show other bugs)
23
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Alexander Dalloz
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-12-26 16:41 EST by Przemek Klosowski
Modified: 2016-01-26 13:28 EST (History)
4 users (show)

See Also:
Fixed In Version: pan-0.140-0.1.20160114git.fc23
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-26 13:28:20 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Przemek Klosowski 2015-12-26 16:41:47 EST
Description of problem:
pan crashes

Version-Release number of selected component (if applicable):
pan-0.139-11.fc23.x86_64

How reproducible: always


Steps to Reproduce:
1. start 'pan'

Actual results:
$ pan
GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name news.pan.NZB was not provided by any .service files
**
ERROR:pan-tree.cc:80:GtkTreeIter PanTreeStore::get_iter(const PanTreeStore::Row*): assertion failed: (row)
Aborted (core dumped)


Expected results: 'pan' runs, opens the News reading window


Additional info:

The error messages are likely a red herring. The coredump happens in the group reading code because of data corruption. 

I ran 'pan' under debugger and set a breakpoint in pan::GroupPane::read_group 


Breakpoint 1 at 0x53330: pan::GroupPane::read_group. (2 locations)
(gdb) r
Starting program: /usr/bin/pan 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
warning: the debug information found in "/usr/lib/debug//lib64/libXi.so.6.1.0.debug" does not match "/lib64/libXi.so.6" (CRC mismatch).

warning: the debug information found in "/usr/lib/debug//usr/lib64/libXi.so.6.1.0.debug" does not match "/lib64/libXi.so.6" (CRC mismatch).

[New Thread 0x7fffe2b4d700 (LWP 7167)]
[New Thread 0x7fffe234c700 (LWP 7168)]
[New Thread 0x7fffe1b4b700 (LWP 7169)]
[New Thread 0x7fffe134a700 (LWP 7170)]
[New Thread 0x7fffe0b49700 (LWP 7171)]
[New Thread 0x7fffdbfff700 (LWP 7172)]
[New Thread 0x7fffdb7fe700 (LWP 7173)]
GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name news.pan.NZB was not provided by any .service files
[New Thread 0x7fffda26e700 (LWP 7175)]

Breakpoint 1, pan::GroupPane::read_group (this=0x5555562a2770, groupname=...) at group-pane.cc:803
803	{
Missing separate debuginfos, use: dnf debuginfo-install libgpg-error-1.21-1.fc23.x86_64 libXi-1.7.6-1.fc23.x86_64

Note that the 'groupname' parameter is bogus:

(gdb) p groupname
$1 = (const pan::StringView &) @0x7fffffffc000: {str = 0x55555639c1c0 "\360\347\071VUU", len = 6}

it is used to look up groups, and results in NULL pointers leading to crash:

(gdb) n
804	    GtkTreeView * view (GTK_TREE_VIEW (_tree_view));
(gdb) 
805	    PanTreeStore * tree (PAN_TREE_STORE(gtk_tree_view_get_model(view)));
(gdb) 
808	    const MyRow* row = find_row (groupname);
(gdb) 
805	    PanTreeStore * tree (PAN_TREE_STORE(gtk_tree_view_get_model(view)));
(gdb) 
808	    const MyRow* row = find_row (groupname);
(gdb) 
809	    iter = tree->get_iter (row);
(gdb) 
**
ERROR:pan-tree.cc:80:GtkTreeIter PanTreeStore::get_iter(const PanTreeStore::Row*): assertion failed: (row)

Program received signal SIGABRT, Aborted.
0x00007ffff3883a98 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:55
55	  return INLINE_SYSCALL (tgkill, 3, pid, selftid, sig);
Comment 1 Przemek Klosowski 2015-12-29 21:31:52 EST
after a series of updates, Pan now works fine without crashing.
It's still the same version pan-0.139-11.fc23.x86_64 so perhaps the problem was with some of Pan dependencies/libraries.

I tried to find Pan dependencies that were recently upgraded. First, I created a list of packages providing Pan dependencies:

dnf repoquery --requires pan | xargs -n1 dnf repoquery --whatprovides

(is there a better way? the above DNF commands have annoying noise in its output and require manual cleanup)

but the resulting list didn't match against recent dnf logs. I seem to remember that DNF is tricky in its handling of requires and provides, so I probably missed something.
Comment 2 Przemek Klosowski 2016-01-04 23:12:34 EST
Sorry premature celebration: pan crashes again.

Perhaps this has nothing to do with updates but rather is caused by differences in saved state? 

The crash happens during dealing with groups. There's problem reading saved state: I have in my ~/.pan2/preferences.xml:

 <string name='last-visited-group' value='sci.electronics.design'/>

but the code presumably reading that value fails to do so:

Breakpoint 1, pan::GUI::root_realized_cb (self_gpointer=0x555555ec7be0) at gui.cc:185
185	  StringView last_group = gui->_prefs.get_string("last-visited-group", "");
            ...stepping forward few instructions...
(gdb) p last_group
$23 = {str = 0x5555563a1be0 "\320o:VUU", len = 22}


The next line checks for empty group, and executes the read_group, 

186	  if (!last_group.empty())
187	  {
188	    gui->_group_pane->read_group(last_group.str);
189	  }

which fails because last_group.str is nonsense
Comment 3 Detlef Graef 2016-01-05 16:11:53 EST
I think this bug is a duplicate of: 1279195

https://bugzilla.redhat.com/show_bug.cgi?id=1279195
Comment 4 Przemek Klosowski 2016-01-08 20:01:59 EST
Reporting a curious fact that I think supports the conclusion of Comment 3: pan does not crash when it is started in the ~/.pan2 directory. The execution is still faulty because instead of reading the stored value of last-visited-group get_string seems to return ""; but at least it avoids the exception because it doesn't try to call read_group.
Comment 5 Fedora Update System 2016-01-14 13:18:45 EST
pan-0.140-0.1.20160114git.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-0b77a47e8b
Comment 6 Fedora Update System 2016-01-15 13:53:01 EST
pan-0.140-0.1.20160114git.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-0b77a47e8b
Comment 7 Fedora Update System 2016-01-26 13:28:14 EST
pan-0.140-0.1.20160114git.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.