return Executor::Execute();
}
+void AppExecutor::DisposeCandidateProcess() {
+ process_pool_->Dispose();
+ process_pool_->SetTimer();
+}
+
void AppExecutor::OnExecution() {
UserTracer::Print(std::to_string(getpid()) + "|after calling fork(). " +
app_info_->GetAppId());
AppExecutor();
pid_t Execute(const AppInfo* app_info);
+ void DisposeCandidateProcess();
private:
void OnExecution() override;
disposed_ = true;
}
-void Debug::Load() {
+bool Debug::Load() {
if (!debugger_infos_.empty())
- return;
+ return false;
DebuggerInfoInflator inflator;
debugger_infos_ = inflator.Inflate(kDebuggerInfoPath);
+ return true;
}
void Debug::PrepareDebugger(const tizen_base::Bundle& b) {
static Debug& GetInst();
void Init();
void Dispose();
- void Load();
+ bool Load();
void PrepareDebugger(const tizen_base::Bundle& b);
std::vector<std::string> GetExtraArgv() const;
std::vector<std::string> GetArgv() const;
Launchpad::LaunchResult Launchpad::ForkProcessing(
std::shared_ptr<Request> request) {
- if (request->GetBundle().GetType(kAulSdk) != BUNDLE_TYPE_NONE)
- Debug::GetInst().Load();
+ if (request->GetBundle().GetType(kAulSdk) != BUNDLE_TYPE_NONE) {
+ if (Debug::GetInst().Load())
+ app_executor_->DisposeCandidateProcess();
+ }
_W("appid: %s", request->GetAppInfo()->GetAppId().c_str());
request->SetPid(app_executor_->Execute(request->GetAppInfo()));