Split RelativePatcher::ReserveSpace() into two.
Instead of passing nullptr and MethodReference(nullptr, 0u)
to ReserveSpace() at the end, call a newly created function
ReserveSpaceEnd().
Change-Id: I38815fe9464b4e1a919878b6e8577614f1058d00
diff --git a/compiler/oat_writer.cc b/compiler/oat_writer.cc
index e15890f..baa6210 100644
--- a/compiler/oat_writer.cc
+++ b/compiler/oat_writer.cc
@@ -357,8 +357,7 @@
bool EndClass() {
OatDexMethodVisitor::EndClass();
if (oat_class_index_ == writer_->oat_classes_.size()) {
- offset_ = writer_->relative_patcher_->ReserveSpace(offset_, nullptr,
- MethodReference(nullptr, 0u));
+ offset_ = writer_->relative_patcher_->ReserveSpaceEnd(offset_);
}
return true;
}