Ruby 3.0.5p211 (2022-11-24 revision ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf)
Data Structures | Macros | Functions
process.h File Reference

Internal header for Process. More...

#include "ruby/internal/config.h"
#include <stddef.h>
#include "ruby/ruby.h"
#include "internal/imemo.h"
#include "internal/warnings.h"

Go to the source code of this file.

Data Structures

struct  rb_execarg
 

Macros

#define RB_MAX_GROUPS   (65536)
 

Functions

rb_pid_t rb_fork_ruby (int *status)
 
void rb_last_status_clear (void)
 
int rb_exec_async_signal_safe (const struct rb_execarg *e, char *errmsg, size_t errmsg_buflen)
 
rb_pid_t rb_fork_async_signal_safe (int *status, int(*chfunc)(void *, char *, size_t), void *charg, VALUE fds, char *errmsg, size_t errmsg_buflen)
 
VALUE rb_execarg_new (int argc, const VALUE *argv, int accept_shell, int allow_exc_opt)
 
struct rb_execargrb_execarg_get (VALUE execarg_obj)
 
int rb_execarg_addopt (VALUE execarg_obj, VALUE key, VALUE val)
 
void rb_execarg_parent_start (VALUE execarg_obj)
 
void rb_execarg_parent_end (VALUE execarg_obj)
 
int rb_execarg_run_options (const struct rb_execarg *e, struct rb_execarg *s, char *errmsg, size_t errmsg_buflen)
 
VALUE rb_execarg_extract_options (VALUE execarg_obj, VALUE opthash)
 
void rb_execarg_setenv (VALUE execarg_obj, VALUE env)
 

Detailed Description

Internal header for Process.

Author
Ruby developers ruby-.nosp@m.core.nosp@m.@ruby.nosp@m.-lan.nosp@m.g.org

Definition in file process.h.

Macro Definition Documentation

◆ RB_MAX_GROUPS

#define RB_MAX_GROUPS   (65536)

Definition at line 27 of file process.h.

Function Documentation

◆ rb_exec_async_signal_safe()

int rb_exec_async_signal_safe ( const struct rb_execarg e,
char *  errmsg,
size_t  errmsg_buflen 
)

Definition at line 3751 of file process.c.

◆ rb_execarg_addopt()

int rb_execarg_addopt ( VALUE  execarg_obj,
VALUE  key,
VALUE  val 
)

◆ rb_execarg_extract_options()

VALUE rb_execarg_extract_options ( VALUE  execarg_obj,
VALUE  opthash 
)

Definition at line 2506 of file process.c.

References Qnil, rb_hash_stlike_foreach(), and RHASH_EMPTY_P.

Referenced by rb_io_popen().

◆ rb_execarg_get()

struct rb_execarg * rb_execarg_get ( VALUE  execarg_obj)

Definition at line 2837 of file process.c.

References TypedData_Get_Struct.

Referenced by rb_execarg_addopt(), rb_execarg_setenv(), and rb_f_exec().

◆ rb_execarg_new()

VALUE rb_execarg_new ( int  argc,
const VALUE argv,
int  accept_shell,
int  allow_exc_opt 
)

Definition at line 2862 of file process.c.

References argc, argv, rb_execarg::exception_given, rb_eArgError, rb_raise(), and TypedData_Make_Struct.

Referenced by rb_f_exec(), and rb_io_popen().

◆ rb_execarg_parent_end()

void rb_execarg_parent_end ( VALUE  execarg_obj)

Definition at line 3082 of file process.c.

References RB_GC_GUARD.

Referenced by rb_execarg_parent_start().

◆ rb_execarg_parent_start()

void rb_execarg_parent_start ( VALUE  execarg_obj)

Definition at line 3043 of file process.c.

References rb_execarg_parent_end(), rb_jump_tag(), and rb_protect().

◆ rb_execarg_run_options()

int rb_execarg_run_options ( const struct rb_execarg e,
struct rb_execarg s,
char *  errmsg,
size_t  errmsg_buflen 
)

◆ rb_execarg_setenv()

void rb_execarg_setenv ( VALUE  execarg_obj,
VALUE  env 
)

Definition at line 2875 of file process.c.

References env, rb_execarg::env_modification, NIL_P, rb_execarg::path_env, Qfalse, and rb_execarg_get().

Referenced by rb_io_popen().

◆ rb_fork_async_signal_safe()

rb_pid_t rb_fork_async_signal_safe ( int status,
int(*)(void *, char *, size_t)  chfunc,
void *  charg,
VALUE  fds,
char *  errmsg,
size_t  errmsg_buflen 
)

◆ rb_fork_ruby()

rb_pid_t rb_fork_ruby ( int status)

◆ rb_last_status_clear()

void rb_last_status_clear ( void  )

Definition at line 666 of file process.c.

References Qnil.