2020-07-26 15:36:28 -04:00
|
|
|
//===-- source/Host/common/PipeBase.cpp -----------------------------------===//
|
2015-02-06 16:38:51 -05:00
|
|
|
//
|
2019-08-20 16:51:52 -04:00
|
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
|
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
|
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
2015-02-06 16:38:51 -05:00
|
|
|
//
|
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
|
|
#include "lldb/Host/PipeBase.h"
|
|
|
|
|
|
|
|
|
|
using namespace lldb_private;
|
|
|
|
|
|
|
|
|
|
PipeBase::~PipeBase() = default;
|
|
|
|
|
|
2017-05-16 15:47:58 -04:00
|
|
|
Status PipeBase::OpenAsWriter(llvm::StringRef name,
|
|
|
|
|
bool child_process_inherit) {
|
2017-01-02 14:26:05 -05:00
|
|
|
return OpenAsWriterWithTimeout(name, child_process_inherit,
|
|
|
|
|
std::chrono::microseconds::zero());
|
2015-02-06 16:38:51 -05:00
|
|
|
}
|
|
|
|
|
|
2017-05-16 15:47:58 -04:00
|
|
|
Status PipeBase::Read(void *buf, size_t size, size_t &bytes_read) {
|
2017-01-02 14:26:05 -05:00
|
|
|
return ReadWithTimeout(buf, size, std::chrono::microseconds::zero(),
|
|
|
|
|
bytes_read);
|
2015-02-06 16:38:51 -05:00
|
|
|
}
|