ART: Remove unnecessary file from vdex

Don't store the file. The mem-map works without it.

Test: m
Test: m test-art-host
Test: device boots
Bug: 30937355
Bug: 31439377
Change-Id: Ie9579062c20ddd8dcfc612ccb614f0a0553d4fd9
diff --git a/runtime/vdex_file.cc b/runtime/vdex_file.cc
index 12bc451..a71578b 100644
--- a/runtime/vdex_file.cc
+++ b/runtime/vdex_file.cc
@@ -19,6 +19,7 @@
 #include <memory>
 
 #include "base/logging.h"
+#include "base/unix_file/fd_file.h"
 
 namespace art {
 
@@ -81,7 +82,7 @@
   }
 
   *error_msg = "Success";
-  return new VdexFile(vdex_file.release(), mmap.release());
+  return new VdexFile(mmap.release());
 }
 
 }  // namespace art
diff --git a/runtime/vdex_file.h b/runtime/vdex_file.h
index e381eb7..9215e52 100644
--- a/runtime/vdex_file.h
+++ b/runtime/vdex_file.h
@@ -21,7 +21,6 @@
 #include <string>
 
 #include "base/macros.h"
-#include "base/unix_file/fd_file.h"
 #include "mem_map.h"
 #include "os.h"
 
@@ -66,9 +65,8 @@
   size_t Size() const { return mmap_->Size(); }
 
  private:
-  VdexFile(File* file, MemMap* mmap) : file_(file), mmap_(mmap) {}
+  explicit VdexFile(MemMap* mmap) : mmap_(mmap) {}
 
-  std::unique_ptr<File> file_;
   std::unique_ptr<MemMap> mmap_;
 
   DISALLOW_COPY_AND_ASSIGN(VdexFile);