Index: runtime/bin/process_macos.cc |
diff --git a/runtime/bin/process_macos.cc b/runtime/bin/process_macos.cc |
index 584968e0821c2d7c8dbbe9ec14a4ecb4c5827df4..30035c5207e124ada283ea097ce01de7d49f7288 100644 |
--- a/runtime/bin/process_macos.cc |
+++ b/runtime/bin/process_macos.cc |
@@ -784,36 +784,6 @@ int Process::Start(const char* path, |
} |
-class BufferList : public BufferListBase { |
- public: |
- BufferList() {} |
- |
- bool Read(int fd, intptr_t available) { |
- // Read all available bytes. |
- while (available > 0) { |
- if (free_size_ == 0) { |
- Allocate(); |
- } |
- ASSERT(free_size_ > 0); |
- ASSERT(free_size_ <= kBufferSize); |
- size_t block_size = dart::Utils::Minimum(free_size_, available); |
- ssize_t bytes = TEMP_FAILURE_RETRY( |
- read(fd, reinterpret_cast<void*>(FreeSpaceAddress()), block_size)); |
- if (bytes < 0) { |
- return false; |
- } |
- data_size_ += bytes; |
- free_size_ -= bytes; |
- available -= bytes; |
- } |
- return true; |
- } |
- |
- private: |
- DISALLOW_COPY_AND_ASSIGN(BufferList); |
-}; |
- |
- |
static bool CloseProcessBuffers(struct pollfd fds[3]) { |
int e = errno; |
VOID_TEMP_FAILURE_RETRY(close(fds[0].fd)); |
@@ -903,6 +873,8 @@ bool Process::Wait(intptr_t pid, |
// All handles closed and all data read. |
result->set_stdout_data(out_data.GetData()); |
result->set_stderr_data(err_data.GetData()); |
+ DEBUG_ASSERT(out_data.IsEmpty()); |
+ DEBUG_ASSERT(err_data.IsEmpty()); |
// Calculate the exit code. |
intptr_t exit_code = exit_code_data.ints[0]; |