| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef NET_TEST_SPAWNED_TEST_SERVER_LOCAL_TEST_SERVER_H_ | 5 #ifndef NET_TEST_SPAWNED_TEST_SERVER_LOCAL_TEST_SERVER_H_ |
| 6 #define NET_TEST_SPAWNED_TEST_SERVER_LOCAL_TEST_SERVER_H_ | 6 #define NET_TEST_SPAWNED_TEST_SERVER_LOCAL_TEST_SERVER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
| 11 #include "base/files/scoped_file.h" |
| 11 #include "base/process/process_handle.h" | 12 #include "base/process/process_handle.h" |
| 12 #include "net/test/spawned_test_server/base_test_server.h" | 13 #include "net/test/spawned_test_server/base_test_server.h" |
| 13 | 14 |
| 14 #if defined(OS_WIN) | 15 #if defined(OS_WIN) |
| 15 #include "base/win/scoped_handle.h" | 16 #include "base/win/scoped_handle.h" |
| 16 #endif | 17 #endif |
| 17 | 18 |
| 18 class CommandLine; | 19 class CommandLine; |
| 19 | 20 |
| 20 namespace net { | 21 namespace net { |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 | 99 |
| 99 // The pipe file handle we read from. | 100 // The pipe file handle we read from. |
| 100 base::win::ScopedHandle child_read_fd_; | 101 base::win::ScopedHandle child_read_fd_; |
| 101 | 102 |
| 102 // The pipe file handle the child and we write to. | 103 // The pipe file handle the child and we write to. |
| 103 base::win::ScopedHandle child_write_fd_; | 104 base::win::ScopedHandle child_write_fd_; |
| 104 #endif | 105 #endif |
| 105 | 106 |
| 106 #if defined(OS_POSIX) | 107 #if defined(OS_POSIX) |
| 107 // The file descriptor the child writes to when it starts. | 108 // The file descriptor the child writes to when it starts. |
| 108 int child_fd_; | 109 base::ScopedFD child_fd_; |
| 109 file_util::ScopedFD child_fd_closer_; | |
| 110 #endif | 110 #endif |
| 111 | 111 |
| 112 DISALLOW_COPY_AND_ASSIGN(LocalTestServer); | 112 DISALLOW_COPY_AND_ASSIGN(LocalTestServer); |
| 113 }; | 113 }; |
| 114 | 114 |
| 115 } // namespace net | 115 } // namespace net |
| 116 | 116 |
| 117 #endif // NET_TEST_SPAWNED_TEST_SERVER_LOCAL_TEST_SERVER_H_ | 117 #endif // NET_TEST_SPAWNED_TEST_SERVER_LOCAL_TEST_SERVER_H_ |
| OLD | NEW |