mirror of
https://github.com/SpartanJ/eepp.git
synced 2026-06-01 11:06:30 +03:00
More DAP WIP.
This commit is contained in:
@@ -5,10 +5,23 @@ namespace ecode {
|
||||
BusProcess::BusProcess( const Command& command ) : mCommand( command ), mProcess() {}
|
||||
|
||||
bool BusProcess::start() {
|
||||
return mProcess.create( mCommand.command, mCommand.arguments,
|
||||
Process::getDefaultOptions() | Process::Options::EnableAsync |
|
||||
Process::Options::CombinedStdoutStderr,
|
||||
mCommand.environment );
|
||||
bool res = mProcess.create( mCommand.command, mCommand.arguments,
|
||||
Process::getDefaultOptions() | Process::Options::EnableAsync |
|
||||
Process::Options::CombinedStdoutStderr,
|
||||
mCommand.environment );
|
||||
if ( res )
|
||||
setState( State::Running );
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
bool BusProcess::close() {
|
||||
if ( mState == State::Running ) {
|
||||
bool res = mProcess.kill();
|
||||
if ( res )
|
||||
setState( State::Closed );
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void BusProcess::startAsyncRead( ReadFn readFn ) {
|
||||
|
||||
Reference in New Issue
Block a user