diff options
author | NIIBE Yutaka <[email protected]> | 2024-10-11 07:17:53 +0000 |
---|---|---|
committer | NIIBE Yutaka <[email protected]> | 2024-10-11 07:29:02 +0000 |
commit | 1860f6407f834b681c21f67db7236eaad161524c (patch) | |
tree | 81e1fee4007e1b70fad278f9716fd65fcc28a7e4 /src/visibility.h | |
parent | w32: Fix releasing memory for UTF-8 text. (diff) | |
download | libgpg-error-1860f6407f834b681c21f67db7236eaad161524c.tar.gz libgpg-error-1860f6407f834b681c21f67db7236eaad161524c.zip |
spawn: Add new function to modify environment.
* src/gpg-error.def.in (gpgrt_spawn_actions_set_envchange): New.
* src/gpg-error.vers (gpgrt_spawn_actions_set_envchange): New.
* src/gpg-error.h.in (gpgrt_spawn_actions_set_envchange): New.
* src/gpgrt-int.h (_gpgrt_spawn_actions_set_envchange): New.
* src/spawn-posix.c (struct gpgrt_spawn_actions): New field ENVCHANGE.
(prepare_environ): New.
(my_exec): Take care of ENVCHANGE.
(_gpgrt_spawn_actions_set_envchange): New.
* src/spawn-w32.c (struct gpgrt_spawn_actions): New field ENVCHANGE.
(prepare_env_block): New.
(_gpgrt_spawn_actions_set_envchange): New.
(spawn_detached, _gpgrt_process_spawn): Take care of ENVCHANGE.
* src/visibility.c (gpgrt_spawn_actions_set_envchange): New.
* src/visibility.h (gpgrt_spawn_actions_set_envchange): New.
* tests/Makefile.am (TESTS): Add t-spawn.
* tests/t-spawn.c: New.
--
GnuPG-bug-id: 7307
Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'src/visibility.h')
-rw-r--r-- | src/visibility.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/visibility.h b/src/visibility.h index 29ebaee..748a42a 100644 --- a/src/visibility.h +++ b/src/visibility.h @@ -231,6 +231,7 @@ MARK_VISIBLE (gpgrt_absfnameconcat) MARK_VISIBLE (gpgrt_spawn_actions_new) MARK_VISIBLE (gpgrt_spawn_actions_release) +MARK_VISIBLE (gpgrt_spawn_actions_set_envchange) #ifdef HAVE_W32_SYSTEM MARK_VISIBLE (gpgrt_spawn_actions_set_envvars) MARK_VISIBLE (gpgrt_spawn_actions_set_redirect) @@ -423,6 +424,7 @@ MARK_VISIBLE (gpgrt_spawn_actions_set_atfork) #define gpgrt_spawn_actions_new _gpgrt_USE_UNDERSCORED_FUNCTION #define gpgrt_spawn_actions_release _gpgrt_USE_UNDERSCORED_FUNCTION +#define gpgrt_spawn_actions_set_envchange _gpgrt_USE_UNDERSCORED_FUNCTION #ifdef HAVE_W32_SYSTEM #define gpgrt_spawn_actions_set_envvars _gpgrt_USE_UNDERSCORED_FUNCTION #define gpgrt_spawn_actions_set_redirect _gpgrt_USE_UNDERSCORED_FUNCTION |