Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/lib/libunwind Fix braino in last commit and free the nod...



details:   https://anonhg.NetBSD.org/src/rev/421113c74c8b
branches:  trunk
changeset: 797526:421113c74c8b
user:      joerg <joerg%NetBSD.org@localhost>
date:      Sun Jul 20 14:40:58 2014 +0000

description:
Fix braino in last commit and free the node iff the insert failed.

diffstat:

 sys/lib/libunwind/AddressSpace.hpp |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r aca4ec156cb7 -r 421113c74c8b sys/lib/libunwind/AddressSpace.hpp
--- a/sys/lib/libunwind/AddressSpace.hpp        Sun Jul 20 14:16:00 2014 +0000
+++ b/sys/lib/libunwind/AddressSpace.hpp        Sun Jul 20 14:40:58 2014 +0000
@@ -402,7 +402,7 @@
     n->data_base = data_base;
     n->ehframe_base = ehframe_base;
 
-    if (static_cast<Range *>(rb_tree_insert_node(&segmentTree, n)) == n) {
+    if (static_cast<Range *>(rb_tree_insert_node(&segmentTree, n)) != n) {
       free(n);
       return;
     }



Home | Main Index | Thread Index | Old Index