-/* Copyright (C) 2000, 2008-2016 Free Software Foundation, Inc.
+/* Copyright (C) 2000, 2008-2021 Free Software Foundation, Inc.
This file is part of the GNU C Library.
This program is free software: you can redistribute it and/or modify
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>. */
+ along with this program. If not, see <https://www.gnu.org/licenses/>. */
#include <sys/types.h>
{
spawn_do_close,
spawn_do_dup2,
- spawn_do_open
+ spawn_do_open,
+ spawn_do_chdir,
+ spawn_do_fchdir
} tag;
union
struct
{
int fd;
- const char *path;
+ char *path;
int oflag;
mode_t mode;
} open_action;
+ struct
+ {
+ char *path;
+ } chdir_action;
+ struct
+ {
+ int fd;
+ } fchdir_action;
} action;
};
#endif
extern int __spawni (pid_t *pid, const char *path,
const posix_spawn_file_actions_t *file_actions,
- const posix_spawnattr_t *attrp, char *const argv[],
- char *const envp[], int use_path);
+ const posix_spawnattr_t *attrp, const char *const argv[],
+ const char *const envp[], int use_path);