Package: pan / 0.146-2

show_threads_dangling_reference.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=749188
Bug-Debian: https://bugs.debian.org/568332
Forwarded: https://bugzilla.gnome.org/show_bug.cgi?id=749188
Author: Lionel Elie Mamane <lionel@mamane.lu>
Origin: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=568332
Description: Show_threads_dangling_reference
 See Debian bug report for details.
--- a/pan/data-impl/my-tree.cc
+++ b/pan/data-impl/my-tree.cc
@@ -316,10 +316,11 @@
   //  maybe include threads or subthreads...
   if (_show_type == Data::SHOW_THREADS)
   {
-    foreach (const_nodes_v, pass, it) {
-      const ArticleNode *& n (*it);
-      while (n->_parent)
-        n = n->_parent;
+    const_nodes_v passcopy=pass;
+    foreach (const_nodes_v, passcopy, it) {
+      const ArticleNode *n (*it);
+      while ((n = n->_parent))
+        pass.push_back(n);
     }
     std::sort (pass.begin(), pass.end(), compare);
     pass.erase (std::unique (pass.begin(), pass.end()), pass.end());