tmux  3.2a
About: tmux is a terminal multiplexer that lets you switch easily between several programs in one terminal.
  Fossies Dox: tmux-3.2a.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

environ.c File Reference
#include <sys/types.h>
#include <fnmatch.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "tmux.h"
Include dependency graph for environ.c:

Go to the source code of this file.

Functions

 RB_HEAD (environ, environ_entry)
 
static int environ_cmp (struct environ_entry *, struct environ_entry *)
 
 RB_GENERATE_STATIC (environ, environ_entry, entry, environ_cmp)
 
struct environenviron_create (void)
 
void environ_free (struct environ *env)
 
struct environ_entryenviron_first (struct environ *env)
 
struct environ_entryenviron_next (struct environ_entry *envent)
 
void environ_copy (struct environ *srcenv, struct environ *dstenv)
 
struct environ_entryenviron_find (struct environ *env, const char *name)
 
void environ_set (struct environ *env, const char *name, int flags, const char *fmt,...)
 
void environ_clear (struct environ *env, const char *name)
 
void environ_put (struct environ *env, const char *var, int flags)
 
void environ_unset (struct environ *env, const char *name)
 
void environ_update (struct options *oo, struct environ *src, struct environ *dst)
 
void environ_push (struct environ *env)
 
void environ_log (struct environ *env, const char *fmt,...)
 
struct environenviron_for_session (struct session *s, int no_TERM)
 

Function Documentation

◆ environ_clear()

void environ_clear ( struct environ env,
const char *  name 
)

◆ environ_cmp()

static int environ_cmp ( struct environ_entry envent1,
struct environ_entry envent2 
)
static

Definition at line 37 of file environ.c.

References environ_entry::name.

◆ environ_copy()

void environ_copy ( struct environ srcenv,
struct environ dstenv 
)

◆ environ_create()

struct environ* environ_create ( void  )

Definition at line 44 of file environ.c.

References environ, and xcalloc().

Referenced by environ_for_session(), LLVMFuzzerInitialize(), main(), and server_client_create().

◆ environ_find()

◆ environ_first()

struct environ_entry* environ_first ( struct environ env)

Definition at line 70 of file environ.c.

References environ.

◆ environ_for_session()

struct environ* environ_for_session ( struct session s,
int  no_TERM 
)

◆ environ_free()

void environ_free ( struct environ env)

Definition at line 56 of file environ.c.

References environ, environ_entry::name, and environ_entry::value.

Referenced by client_main(), server_client_lost(), session_free(), and spawn_pane().

◆ environ_log()

void environ_log ( struct environ env,
const char *  fmt,
  ... 
)

Definition at line 224 of file environ.c.

References environ, log_debug(), environ_entry::name, environ_entry::value, and vasprintf().

Referenced by spawn_pane().

◆ environ_next()

struct environ_entry* environ_next ( struct environ_entry envent)

Definition at line 76 of file environ.c.

References environ.

◆ environ_push()

void environ_push ( struct environ env)

◆ environ_put()

void environ_put ( struct environ env,
const char *  var,
int  flags 
)

◆ environ_set()

void environ_set ( struct environ env,
const char *  name,
int  flags,
const char *  fmt,
  ... 
)

◆ environ_unset()

void environ_unset ( struct environ env,
const char *  name 
)

Definition at line 168 of file environ.c.

References environ, environ_find(), name, environ_entry::name, and environ_entry::value.

◆ environ_update()

void environ_update ( struct options oo,
struct environ src,
struct environ dst 
)

◆ RB_GENERATE_STATIC()

RB_GENERATE_STATIC ( environ  ,
environ_entry  ,
entry  ,
environ_cmp   
)

◆ RB_HEAD()

RB_HEAD ( environ  ,
environ_entry   
)