diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2024-03-14 17:35:09 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2024-03-14 17:59:52 +0200 |
commit | e879cd3085ff09f2ff7aff88b9a725d69f209a24 (patch) | |
tree | f16d044f42aa19faa5f1f0d0e7c5ec12d89f5fe2 /runcap.h | |
parent | 33ab56c03ef99f1d9f508090d3452a78496cfe93 (diff) | |
download | runcap-master.tar.gz runcap-master.tar.bz2 |
* runcap.3: Document changes.
* runcap.c (runcap_start): Set environ if rc->rc_env is not NULL.
(runcap_init): Initialize rc->rc_env with NULL if RCF_ENV is not set.
* runcap.h (struct runcap): New field: rc_env.
(RCF_ENV): New flag.
* t/env.at: New test.
* t/Makefile.am: Add new test.
* t/testsuite.at: Likewise.
* t/rt.c: New option: -e (modify environment).
Diffstat (limited to 'runcap.h')
-rw-r--r-- | runcap.h | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -47,6 +47,7 @@ struct runcap { char *rc_program; /* [IN] (Path)name of the program to run */ char **rc_argv; /* [IN] Argument vector */ + char **rc_env; /* [IN] Environment variables */ unsigned rc_timeout; /* [IN] Execution timeout */ struct stream_capture rc_cap[RUNCAP_NBUF]; /* rc_cap[RUNCAP_STDIN] - [IN], rest - [OUT] */ @@ -58,6 +59,7 @@ struct runcap #define RCF_PROGRAM 0x0001 /* rc_program is set */ #define RCF_TIMEOUT 0x0002 /* rc_timeout is set */ #define RCF_STDIN 0x0004 /* rc_cap[RUNCAP_STDIN] is set */ +#define RCF_ENV 0x0008 /* rc_env is set */ #define RCF_SC_SIZE 0x1 /* sc_size is set */ #define RCF_SC_LINEMON 0x2 /* sc_linemon is set*/ |