2
0
mirror of https://github.com/boostorg/process.git synced 2026-01-19 16:32:15 +00:00
Commit Graph

435 Commits

Author SHA1 Message Date
Klemens Morgenstern
a2d2753aa8 zombie process fixes
closes #445, #447
2025-01-13 09:31:48 +08:00
Klemens Morgenstern
1b5272a9e1 changed cwd comparison to equivalent. 2025-01-13 08:36:36 +08:00
Jonas Greitemann
4bb842564f add a (failing) test for process_stdio move semantics
This test currently fails on POSIX, as `process_io_binding` does not
explicitly implement move operations but holds on to a file descriptor
which exhibits reference semantics and has a non-trivial destructor.

The same test should pass on Windows as the Windows implementation makes
use of `unique_ptr` which gives it correct move semantics by virtue of
the rule of zero.
2025-01-13 08:13:33 +08:00
Jonas Greitemann
359820097b add test case for initializing process_stdio with complementary pipe ends
`process_stdio` holds on to the handles for `in`/`out`/`err`. In case of
pipes, `in` needs the handles of a `readable_pipe`, whereas `out` and
`err` need the handles of `writable_pipe`s. So far, the tests all create
a new pair using `connect_pipe`, pass the "correct" end into
`process_stdio`, and use the other end to interface with the process.

However, `process_io_binding` also supports construction from the
complementary pipe types, i.e., constructing `in`'s binding from a
`writable_pipe` and `out`/`err`'s bindings from `readable_pipe`s.
In this case, the constructor will create the corresponding pipe itself
and keep ownership of it. This mode was thus far not tested.
2025-01-13 08:13:33 +08:00
Klemens Morgenstern
b529769eb5 removed boost::system:: scope spec for error_code. 2024-12-20 20:53:29 +08:00
Klemens Morgenstern
2ccd97cd48 made v2 the default 2024-12-20 20:53:29 +08:00
Klemens Morgenstern
662c0b10e3 warning fixes
Closes #436, #437
2024-12-13 11:58:39 +08:00
Klemens Morgenstern
fa83c2f9ff fixes the exit-code error on osx builds. 2024-11-19 07:41:31 +08:00
Samuel Venable
7e5dd4075f bp2::ext::env() Fixes (#415)
* Implement OpenBSD Executable PatH
* Static Cast Device and iNode
* Add Name Spaces to Exe Checker
* Strings to File System Paths

---------

Co-authored-by: freebsd <freebsd@freebsd.lan>
2024-10-30 09:05:20 +08:00
Samuel Venable
8a8ca8b7ab OpenBSD fix & Solaris fixes
[DragonFly BSD] Use Proper CWD From PID Code
2024-10-30 09:05:20 +08:00
Klemens Morgenstern
f218a6a6c1 added pthread to test linking for freebsd on v1 as well. 2024-10-30 08:09:28 +08:00
Klemens Morgenstern
11a0d0d7c1 added pthread to test linking for freebsd 2024-10-30 08:09:28 +08:00
Klemens Morgenstern
e46a514629 replaced deadline_timer with steady_timer. 2024-10-30 08:09:28 +08:00
Klemens Morgenstern
36954338d8 remove test_impl lib 2024-10-30 08:09:28 +08:00
Klemens Morgenstern
eb6b49c090 disabled /boost//coroutine dependent tests 2024-10-30 08:09:28 +08:00
Klemens Morgenstern
928674d2e3 added test async_wait cancellation test. 2024-10-30 08:09:28 +08:00
René Ferdinand Rivera Morell
9761be99bb Add support for modular build structure. (#389)
* Make the library modular usable.

* Switch to library requirements instead of source. As source puts extra source in install targets.

* Add requires-b2 check to top-level build file.

* Add missing test deps.

* Bump B2 require to 5.2

* Fix duplicate def of boost.process.fs feature.

* Add missing boost_test dependency.

* Move inter-lib dependencies to a project variable and into the build targets.

* Switch to /boost/test//included target for header only mode of Boost.Test.

* Adjust doc build to avoid boost-root references.

* Update build deps.

* Fix link and build of deps.
2024-10-30 08:09:27 +08:00
Klemens Morgenstern
8b3e90234b b2 link fixes. 2024-07-12 09:03:08 +08:00
Klemens Morgenstern
c2da58e548 added exit_code timeout. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
084a85fc6e switched to run_for in exit_code.cpp. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
2171367d97 added completion to spawn in tests. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
67a92df441 fixed missing return. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
c773ee16cf replaced v2 .ipp with lib. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
44cae64d49 minor fixes. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
55e2460967 moved v1 to v1 inline namespace. 2024-07-02 21:06:23 +08:00
Klemens Morgenstern
bcdd91188c move everything v1 to v1 folders 2024-07-02 21:06:23 +08:00
Daniel Klauer
e455a12e2c posix: Add test for pipe fd leak if redirecting both stdout and stderr
Signed-off-by: Daniel Klauer <daniel.klauer@gin.de>
2024-06-04 08:54:21 +08:00
Daniel Klauer
0058a9c69f posix: Fix exec error reporting with limit_handles
_pipe_sink was assigned after call_on_setup(), after limit_fd_::on_setup(),
but this was too late. It must be assigned earlier so that
executor::get_used_handles() can see it and prevent limit_handles from
closing the internal pipe for passing exec() errors from child to parent.

Fixes: 1a1d677d
Closes: https://github.com/boostorg/process/issues/202
Signed-off-by: Daniel Klauer <daniel.klauer@gin.de>
2024-06-04 08:19:54 +08:00
Klemens Morgenstern
46acb247f5 test include fix. 2024-03-28 11:05:33 +08:00
Klemens Morgenstern
8d9aa1e31d incresed request_exit delay in windows process test. 2023-10-13 14:25:04 +08:00
Daniel Richard G
f17be678f2 fix group_wait test in cmake build. 2023-10-09 10:46:03 +08:00
Klemens Morgenstern
69c2c25729 added SIGTERM bit mask for freeBSD. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
8ab2332327 v2/env win test fix. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
ea69cda6d8 added can_interrupt check on windows to win tests. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
6b75b4039f increased timeout & added diagnostics. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
3c1beb40f6 windows move handle fix. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
e51970e3bb fixed windows interrupt & request_exit test. 2023-10-05 06:52:20 +08:00
Klemens
f3f8548dea allowing for SIGTERM in exit code on posix interrupts. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
4b7a00d4cf target: global timer workaround helper. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
3769ec01f4 process native-exit code test. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
cf14d54343 pid no-access workarounds. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
b81cac8042 moved interrupt & request_exit into target. 2023-10-05 06:52:20 +08:00
Klemens Morgenstern
7b6b93691f fixed executor reset_cancellation_state.
Closes #338.
2023-10-05 06:52:20 +08:00
Klemens Morgenstern
c005adc8fc simplified stdio. 2023-06-28 20:24:12 +08:00
Klemens Morgenstern
5cab462710 added empty env var check to tests. 2023-06-28 20:24:12 +08:00
Klemens Morgenstern
ccd46dc692 added Bcrypt to gcc win builds. 2023-06-28 20:24:12 +08:00
Klemens Morgenstern
b3c8c3a8da fixed popen test. 2023-06-28 20:24:12 +08:00
Klemens Morgenstern
4dd6f28094 removed code_as_error. 2023-06-28 20:24:12 +08:00
Klemens Morgenstern
d73f228469 popen test adjustements. 2023-06-28 20:24:12 +08:00
Klemens Morgenstern
ccd1717588 test updates for CI 2023-06-28 20:24:12 +08:00