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

Unified Diff: components/nacl/browser/nacl_browser.h

Issue 286143010: Remove knowledge of nacl from content. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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
« no previous file with comments | « chrome/browser/task_manager/task_manager.cc ('k') | components/nacl/browser/nacl_browser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/nacl/browser/nacl_browser.h
diff --git a/components/nacl/browser/nacl_browser.h b/components/nacl/browser/nacl_browser.h
index 651e2f8692e3ec0b2c7ff0878c4a8a725ed08c5e..51d19e4efdd89512bdbaa17ee85579c58c01ef57 100644
--- a/components/nacl/browser/nacl_browser.h
+++ b/components/nacl/browser/nacl_browser.h
@@ -25,6 +25,9 @@ class FileProxy;
namespace nacl {
+static const int kGdbDebugStubPortUnknown = -1;
+static const int kGdbDebugStubPortUnused = 0;
+
// Open an immutable executable file that can be mmapped.
// This function should only be called on a thread that can perform file IO.
base::File OpenNaClExecutableImpl(const base::FilePath& file_path);
@@ -65,11 +68,12 @@ class NaClBrowser {
// debug stub server instead of a fixed one.
// Notify listener that new debug stub TCP port is allocated.
- void FireGdbDebugStubPortOpened(int port);
- bool HasGdbDebugStubPortListener();
+ void SetProcessGdbDebugStubPort(int process_id, int port);
void SetGdbDebugStubPortListener(base::Callback<void(int)> listener);
void ClearGdbDebugStubPortListener();
+ int GetProcessGdbDebugStubPort(int process_id);
+
bool ValidationCacheIsEnabled() const {
return validation_cache_is_enabled_;
}
@@ -117,6 +121,8 @@ class NaClBrowser {
static void SetDelegate(NaClBrowserDelegate* delegate);
static NaClBrowserDelegate* GetDelegate();
+ // Each time a NaCl process ends, the browser is notified.
+ void OnProcessEnd(int process_id);
// Support for NaCl crash throttling.
// Each time a NaCl module crashes, the browser is notified.
void OnProcessCrashed();
@@ -171,6 +177,10 @@ class NaClBrowser {
NaClResourceState validation_cache_state_;
base::Callback<void(int)> debug_stub_port_listener_;
+ // Map from process id to debug stub port if any.
+ typedef std::map<int, int> GdbDebugStubPortMap;
+ GdbDebugStubPortMap gdb_debug_stub_port_map_;
+
typedef base::HashingMRUCache<std::string, base::FilePath> PathCacheType;
PathCacheType path_cache_;
« no previous file with comments | « chrome/browser/task_manager/task_manager.cc ('k') | components/nacl/browser/nacl_browser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698