OSDN Git Service

loader: fix leak of child-to-parent links on dlclose()
authorDimitry Ivanov <dimitry@google.com>
Sat, 22 Apr 2017 00:44:25 +0000 (17:44 -0700)
committerDimitry Ivanov <dimitry@google.com>
Sat, 22 Apr 2017 00:46:24 +0000 (17:46 -0700)
Remove the code adding link from child to parent. The link is
not used anywhere in the linker for L release.

Bug: 36104177
Test: manual - dlopen/dlclose libandroid.so 10 times and see how many blocks are
      used after each dlclose() - make sure they are constant.

Change-Id: I57039e934ba233253ad7dce2e071833528460116

linker/linker.cpp

index cf65705..9ade46d 100644 (file)
@@ -1539,7 +1539,6 @@ void soinfo::add_child(soinfo* child) {
   }
 
   this->children.push_front(child);
-  child->parents.push_front(this);
 }
 
 void soinfo::remove_all_links() {