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

Unified Diff: chromeos/process_proxy/process_output_watcher.h

Issue 1135823007: Prevent ProcessProxy from passing bad fds to ProcessOutputWatcher (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 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 | « no previous file | chromeos/process_proxy/process_output_watcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/process_proxy/process_output_watcher.h
diff --git a/chromeos/process_proxy/process_output_watcher.h b/chromeos/process_proxy/process_output_watcher.h
index 598fd5fa1e3c72a0f96b2cbe4cdbbc2b32c66041..eb0d046c4f46c16f48b151add8651f27e8af581b 100644
--- a/chromeos/process_proxy/process_output_watcher.h
+++ b/chromeos/process_proxy/process_output_watcher.h
@@ -28,6 +28,9 @@ typedef base::Callback<void(ProcessOutputType, const std::string&)>
// underlying thread block. It deletes itself when watching is stopped.
class CHROMEOS_EXPORT ProcessOutputWatcher {
public:
+ // Verifies that fds that we got are properly set.
+ static bool VerifyFileDescriptor(int fd);
+
ProcessOutputWatcher(int out_fd, int stop_fd,
const ProcessOutputCallback& callback);
@@ -43,9 +46,6 @@ class CHROMEOS_EXPORT ProcessOutputWatcher {
// fds, it would be nicer if it was).
void WatchProcessOutput();
- // Verifies that fds that we got are properly set.
- void VerifyFileDescriptor(int fd);
-
// Reads data from fd, and when it's done, invokes callback function.
void ReadFromFd(ProcessOutputType type, int* fd);
« no previous file with comments | « no previous file | chromeos/process_proxy/process_output_watcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698