Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(442)

Unified Diff: ppapi/native_client/src/trusted/plugin/plugin.h

Issue 14750007: NaCl: enable meta-based validation for shared libraries. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comment Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ppapi/native_client/src/trusted/plugin/plugin.h
diff --git a/ppapi/native_client/src/trusted/plugin/plugin.h b/ppapi/native_client/src/trusted/plugin/plugin.h
index 37bcfdd1b6e7ba268a9fa6eaa34109121fc67884..eecddc64607c929da5b38bfde708bdb6cb2669b8 100644
--- a/ppapi/native_client/src/trusted/plugin/plugin.h
+++ b/ppapi/native_client/src/trusted/plugin/plugin.h
@@ -24,6 +24,7 @@
#include "native_client/src/trusted/plugin/pnacl_coordinator.h"
#include "native_client/src/trusted/plugin/service_runtime.h"
#include "native_client/src/trusted/plugin/utility.h"
+#include "native_client/src/trusted/validator/nacl_file_info.h"
#include "ppapi/c/private/ppb_nacl_private.h"
#include "ppapi/cpp/private/var_private.h"
@@ -252,9 +253,11 @@ class Plugin : public pp::InstancePrivate {
// corresponding to the url body is recorded for further lookup.
bool StreamAsFile(const nacl::string& url,
PP_CompletionCallback pp_callback);
- // Returns an open POSIX file descriptor retrieved by StreamAsFile()
- // or NACL_NO_FILE_DESC. The caller must take ownership of the descriptor.
- int32_t GetPOSIXFileDesc(const nacl::string& url);
+
+ // Returns rich information for a file retrieved by StreamAsFile(). This info
+ // contains a file descriptor. The caller must take ownership of this
+ // descriptor.
+ struct NaClFileInfo GetFileInfo(const nacl::string& url);
// A helper function that gets the scheme type for |url|. Uses URLUtil_Dev
// interface which this class has as a member.
@@ -475,7 +478,7 @@ class Plugin : public pp::InstancePrivate {
std::set<FileDownloader*> url_downloaders_;
// Keep track of file descriptors opened by StreamAsFile().
// These are owned by the browser.
- std::map<nacl::string, int32_t> url_fd_map_;
+ std::map<nacl::string, struct NaClFileInfo> url_file_info_map_;
// Pending progress events.
std::queue<ProgressEvent*> progress_events_;

Powered by Google App Engine
This is Rietveld 408576698