aboutsummaryrefslogtreecommitdiff
path: root/src/util/subprocess.h
diff options
context:
space:
mode:
authorSebastian Falbesoner <sebastian.falbesoner@gmail.com>2024-04-27 14:36:32 +0200
committerSebastian Falbesoner <sebastian.falbesoner@gmail.com>2024-04-28 14:17:14 +0200
commit97f159776ec06f767df1d4990aa7d0859140f52f (patch)
tree5d1522cf3e61ed92b8b7abb0428dbca92b2d183e /src/util/subprocess.h
parent908c51fe4afeba0af500c6275027b1afa1b3bd19 (diff)
remove unused method `Popen::kill` from cpp-subprocess
Diffstat (limited to 'src/util/subprocess.h')
-rw-r--r--src/util/subprocess.h17
1 files changed, 0 insertions, 17 deletions
diff --git a/src/util/subprocess.h b/src/util/subprocess.h
index dfe6e63c1a..8c5f074918 100644
--- a/src/util/subprocess.h
+++ b/src/util/subprocess.h
@@ -905,7 +905,6 @@ private:
* 4. retcode() - The return code of the exited child.
* 5. pid() - PID of the spawned child.
* 6. poll() - Check the status of the running child.
- * 7. kill(sig_num) - Kill the child. SIGTERM used by default.
* 8. send(...) - Send input to the input channel of the child.
* 9. communicate(...) - Get the output/error from the child and close the channels
* from the parent side.
@@ -966,10 +965,6 @@ public:
int poll() noexcept(false);
- // Does not fail, Caller is expected to recheck the
- // status with a call to poll()
- void kill(int sig_num = 9);
-
void set_out_buf_cap(size_t cap) { stream_.set_out_buf_cap(cap); }
void set_err_buf_cap(size_t cap) { stream_.set_err_buf_cap(cap); }
@@ -1137,18 +1132,6 @@ inline int Popen::poll() noexcept(false)
#endif
}
-inline void Popen::kill(int sig_num)
-{
-#ifdef __USING_WINDOWS__
- if (!TerminateProcess(this->process_handle_, (UINT)sig_num)) {
- throw OSError("TerminateProcess", 0);
- }
-#else
- ::kill(child_pid_, sig_num);
-#endif
-}
-
-
inline void Popen::execute_process() noexcept(false)
{
#ifdef __USING_WINDOWS__