mirror of
https://github.com/boostorg/process.git
synced 2026-01-20 04:42:24 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9ed2fef8cd |
@@ -411,8 +411,7 @@ struct default_launcher
|
||||
if (ec)
|
||||
{
|
||||
detail::on_error(*this, executable, argv, ec, inits...);
|
||||
int res = 0;
|
||||
do { res = ::waitpid(pid, nullptr, 0); } while ((res == -1) && (errno == EINTR));
|
||||
do { ::waitpid(pid, nullptr, 0); } while (errno == EINTR);
|
||||
return basic_process<Executor>{exec};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -124,8 +124,7 @@ struct fork_and_forget_launcher : default_launcher
|
||||
if (ec)
|
||||
{
|
||||
detail::on_error(*this, executable, argv, ec, inits...);
|
||||
int res = 0;
|
||||
do { res = ::waitpid(pid, nullptr, 0); } while ((res != -1) && (errno == EINTR));
|
||||
do { ::waitpid(pid, nullptr, 0); } while (errno == EINTR);
|
||||
return basic_process<Executor>{exec};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -161,8 +161,7 @@ struct pdfork_launcher : default_launcher
|
||||
if (ec)
|
||||
{
|
||||
detail::on_error(*this, executable, argv, ec, inits...);
|
||||
int res = 0;
|
||||
do { res = ::waitpid(pid, nullptr, 0); } while ((res == -1) && (errno == EINTR));
|
||||
do { ::waitpid(pid, nullptr, 0); } while (errno == EINTR);
|
||||
return basic_process<Executor>{exec};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -121,8 +121,7 @@ struct vfork_launcher : default_launcher
|
||||
if (ec)
|
||||
{
|
||||
detail::on_error(*this, executable, argv, ec, inits...);
|
||||
int res = 0;
|
||||
do { res = ::waitpid(pid, nullptr, 0); } while ((res != -1) && (errno == EINTR));
|
||||
do { ::waitpid(pid, nullptr, 0); } while (errno == EINTR);
|
||||
return basic_process<Executor>{exec};
|
||||
}
|
||||
|
||||
|
||||
@@ -109,7 +109,7 @@ inline std::false_type probe_on_error(
|
||||
|
||||
template<typename Launcher, typename Init>
|
||||
inline auto probe_on_error(Launcher & launcher, Init && init, derived && )
|
||||
-> std::is_same<error_code, decltype(init.on_error(launcher, std::declval<const filesystem::path &>(), std::declval<std::wstring &>(), std::declval<std::error_code&>()))>;
|
||||
-> std::is_same<error_code, decltype(init.on_error(launcher, std::declval<const filesystem::path &>(), std::declval<std::wstring &>(), std::declval<error_code&>()))>;
|
||||
|
||||
template<typename Launcher, typename Init>
|
||||
using has_on_error = decltype(probe_on_error(std::declval<Launcher&>(), std::declval<Init>(), derived{}));
|
||||
|
||||
Reference in New Issue
Block a user