Increase startup wait timeout to 5 seconds
authorIgor Kulaychuk <i.kulaychuk@samsung.com>
Wed, 19 Jul 2017 00:40:07 +0000 (03:40 +0300)
committerIgor Kulaychuk <i.kulaychuk@samsung.com>
Mon, 13 Nov 2017 19:22:40 +0000 (22:22 +0300)
src/debug/netcoredbg/commands.cpp
src/debug/netcoredbg/main.cpp

index 5070c57..d6675ec 100644 (file)
@@ -390,7 +390,10 @@ HRESULT Debugger::HandleCommand(std::string command,
         return S_OK;
     }},
     { "exec-run", [this](ICorDebugProcess *, const std::vector<std::string> &args, std::string &output) -> HRESULT {
-        return RunProcess(); // TODO return ~running
+        HRESULT Status = RunProcess();
+        if (SUCCEEDED(Status))
+            output = "^running";
+        return Status;
     }},
     { "handshake", [](ICorDebugProcess *, const std::vector<std::string> &args, std::string &output) -> HRESULT {
         if (!args.empty() && args.at(0) == "init")
index fa6349f..697db99 100644 (file)
@@ -833,7 +833,7 @@ HRESULT Debugger::Startup(IUnknown *punk, int pid)
 
 HRESULT Debugger::RunProcess()
 {
-    static const auto startupCallbackWaitTimeout = std::chrono::milliseconds(1000);
+    static const auto startupCallbackWaitTimeout = std::chrono::milliseconds(5000);
     HRESULT Status;
 
     IfFailRet(CheckNoProcess());