#include "shell.h"#include "main.h"#include "nodes.h"#include "parser.h"#include "redir.h"#include "eval.h"#include "exec.h"#include "builtins.h"#include "var.h"#include "options.h"#include "input.h"#include "output.h"#include "syntax.h"#include "memalloc.h"#include "error.h"#include "init.h"#include "mystring.h"#include <sys/types.h>#include <sys/stat.h>#include <fcntl.h>#include <errno.h>#include <limits.h>Include dependency graph for exec.c:

Go to the source code of this file.
Data Structures | |
| struct | tblentry |
Defines | |
| #define | CMDTABLESIZE 31 |
| #define | ARB 1 |
Functions | |
| STATIC void | tryexec () |
| STATIC void | execinterp () |
| STATIC void | printentry () |
| STATIC void | clearcmdentry () |
| STATIC struct tblentry * | cmdlookup () |
| STATIC void | delete_cmd_entry () |
| void | shellexec (char **argv, char **envp, char *path, index) |
| STATIC void | tryexec (char *cmd, char **argv, char **envp) |
| char * | padvance (char **path, char *name) |
| hashcmd (argc, char **argv) | |
| STATIC void | printentry (struct tblentry *cmdp) |
| void | find_command (char *name, struct cmdentry *entry, printerr) |
| int | find_builtin (char *name) |
| void | hashcd () |
| void | changepath (char *newval) |
| STATIC void | clearcmdentry (firstchange) |
| void | deletefuncs () |
| STATIC struct tblentry * | cmdlookup (char *name, add) |
| void | addcmdentry (char *name, struct cmdentry *entry) |
| void | defun (char *name, union node *func) |
| void | unsetfunc (char *name) |
Variables | |
| static char | sccsid [] = "@(#)exec.c 5.2 (Berkeley) 3/13/91" |
| STATIC struct tblentry * | cmdtable [CMDTABLESIZE] |
| STATIC int | builtinloc = -1 |
| char * | pathopt |
| tblentry ** | lastcmdentry |
|
|
|
|
|
Definition at line 74 of file exec.c. Referenced by clearcmdentry(), cmdlookup(), deletefuncs(), hashcd(), and hashcmd(). |
|
||||||||||||
|
Definition at line 774 of file exec.c. References CMDFUNCTION, cmdlookup(), cmdp, entry, INTOFF, and INTON. Referenced by defun(). |
|
|
|
|
|
Definition at line 628 of file exec.c. References builtinloc, ckfree, CMDBUILTIN, CMDNORMAL, cmdp, cmdtable, CMDTABLESIZE, INTOFF, and NULL. |
|
|
|
|
||||||||||||
|
Definition at line 698 of file exec.c. References cmdp, cmdtable, CMDTABLESIZE, and equal. |
|
|
Referenced by addcmdentry(), find_command(), and unsetfunc(). |
|
||||||||||||
|
Definition at line 796 of file exec.c. References addcmdentry(), CMDFUNCTION, entry, func, INTOFF, and INTON. Referenced by evaltree(), and lccmd(). |
|
|
Definition at line 737 of file exec.c. References ckfree, cmdp, INTOFF, INTON, and lastcmdentry. Referenced by unsetfunc(). |
|
|
Definition at line 663 of file exec.c. References ckfree, CMDFUNCTION, cmdp, cmdtable, CMDTABLESIZE, INTOFF, and NULL. |
|
|
Referenced by tryexec(). |
|
|
Definition at line 541 of file exec.c. Referenced by evalcommand(), and find_command(). |
|
||||||||||||||||
|
Definition at line 394 of file exec.c. References builtinloc, CMDBUILTIN, CMDFUNCTION, cmdlookup(), CMDNORMAL, cmdp, e, EACCES, EINTR, ENOENT, ENOTDIR, entry, errno, error, find_builtin(), getegid, geteuid, getgroups, index(), INTOFF, INTON, loop, ngroups, NULL, padvance(), path, pathopt, pathval, prefix, readcmdfile(), S_IFMT, S_IFREG, stat::st_gid, stat::st_mode, stat::st_uid, stalloc(), stat, strchr, strlen(), stunalloc(), and TRACE. Referenced by evalcommand(), and prehash(). |
|
|
Definition at line 561 of file exec.c. References builtinloc, CMDBUILTIN, CMDNORMAL, cmdp, cmdtable, and CMDTABLESIZE. |
|
||||||||||||
|
Definition at line 313 of file exec.c. References argc, cmdp, cmdtable, CMDTABLESIZE, entry, printentry(), and verbose. |
|
||||||||||||
|
Definition at line 274 of file exec.c. References bcopy, growstackblock(), NULL, stackblock, stackblocksize, stalloc(), start, strcpy(), and strlen(). Referenced by cdcmd(), chkmail(), find_command(), printentry(), and shellexec(). |
|
|
Definition at line 357 of file exec.c. References CMDBUILTIN, CMDFUNCTION, CMDNORMAL, error, index(), out1c, out1fmt(), out1str(), padvance(), path, pathval, and stunalloc(). |
|
|
Referenced by hashcmd(). |
|
||||||||||||||||||||
|
Definition at line 116 of file exec.c. References tblentry::cmdname, e, E_EXEC, ENOENT, ENOTDIR, errmsg, errno, error2(), index(), NULL, padvance(), pathopt, strchr, stunalloc(), and tryexec(). Referenced by execcmd(). |
|
||||||||||||||||
|
Definition at line 142 of file exec.c. References arg0, commandname, e, EINTR, ENOEXEC, errno, execinterp(), execve, exraise(), EXSHELLPROC, initshellproc(), p, parsenextc, parsenleft, pgetc(), pungetc(), savestr, setinputfile(), and setparam(). |
|
|
Referenced by shellexec(). |
|
|
Definition at line 815 of file exec.c. References CMDFUNCTION, cmdlookup(), cmdp, delete_cmd_entry(), and NULL. Referenced by unsetcmd(). |
|
|
Definition at line 89 of file exec.c. Referenced by clearcmdentry(), find_command(), and hashcd(). |
|
|
Definition at line 88 of file exec.c. Referenced by clearcmdentry(), cmdlookup(), deletefuncs(), hashcd(), and hashcmd(). |
|
|
Definition at line 694 of file exec.c. Referenced by delete_cmd_entry(). |
|
|
Definition at line 271 of file exec.c. Referenced by chkmail(), find_command(), and shellexec(). |
|
|
|
1.4.6