linker: hide the pointer to soinfo
Handle no longer is a pointer to soinfo of
a corresponding library. This is done to
prevent access to linker internal fields.
Bug: http://b/25593965
Change-Id: I62bff0d0e5b2dc842e6bf0babb30fcc4c000be24
diff --git a/linker/linked_list.h b/linker/linked_list.h
index 88386b0..092e831 100644
--- a/linker/linked_list.h
+++ b/linker/linked_list.h
@@ -43,7 +43,7 @@
return *this;
}
- T* operator*() {
+ T* const operator*() {
return entry_->element;
}
@@ -190,15 +190,15 @@
return nullptr;
}
- iterator begin() {
+ iterator begin() const {
return iterator(head_);
}
- iterator end() {
+ iterator end() const {
return iterator(nullptr);
}
- iterator find(T* value) {
+ iterator find(T* value) const {
for (LinkedListEntry<T>* e = head_; e != nullptr; e = e->next) {
if (e->element == value) {
return iterator(e);