summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Carlstrom <bdc@google.com>2014-02-10 18:00:04 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-02-10 18:00:04 +0000
commit3ece181223974d8c081fb88cfbec8d85fd194d66 (patch)
treefdcba42b06388b1307584f9b9597700e524a763d
parent8aaeb4851b20f67fc0eb7564e3c831277f832bb8 (diff)
parent093713f916bfaaf32413b80334a9997bcadddc4c (diff)
downloadart-3ece181223974d8c081fb88cfbec8d85fd194d66.tar.gz
art-3ece181223974d8c081fb88cfbec8d85fd194d66.tar.bz2
art-3ece181223974d8c081fb88cfbec8d85fd194d66.zip
Merge changes Id416ea15,I725ce638
* changes: Fix Portable build Change GetPortableCode result from reference to pointer
-rw-r--r--compiler/elf_writer_mclinker.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/elf_writer_mclinker.cc b/compiler/elf_writer_mclinker.cc
index e56f5f894..c7baf4f3e 100644
--- a/compiler/elf_writer_mclinker.cc
+++ b/compiler/elf_writer_mclinker.cc
@@ -265,12 +265,12 @@ void ElfWriterMclinker::AddCompiledCodeInput(const CompiledCode& compiled_code)
added_symbols_.Put(&symbol, &symbol);
// Add input to supply code for symbol
- const std::vector<uint8_t>& code = compiled_code.GetPortableCode();
+ const std::vector<uint8_t>* code = compiled_code.GetPortableCode();
// TODO: ownership of code_input?
// TODO: why does IRBuilder::ReadInput take a non-const pointer?
mcld::Input* code_input = ir_builder_->ReadInput(symbol,
- const_cast<uint8_t*>(&code[0]),
- code.size());
+ const_cast<uint8_t*>(&(*code)[0]),
+ code->size());
CHECK(code_input != NULL);
}