/* * ep - extended pipelining * * process.h - process structure header file * ____________________________________________________________ * * Developed by Ondrej Jombik * and Lubomir Host * Copyright (c) 2000-2003 Platon SDG, http://platon.sk/ * All rights reserved. * * See README file for more information about this software. * See COPYING file for license information. * * Download the latest version from * http://platon.sk/projects/ep/ */ /* $Platon: ep/src/process.h,v 1.12 2003/05/03 09:58:19 nepto Exp $ */ #ifndef _PROCESS_H #define _PROCESS_H #include "fd.h" #include "proclink.h" struct process { /* System process ID number. */ int pid; /* System priority. */ int nice; /* List of process names ended with NULL. */ char **name; /* List of process arguments ended with NULL. */ char **argv; /* Filedescriptors. */ struct fd fd[N_FD]; }; /* Initialize empty struct process. */ void process_init(struct process *proc); /* Destroy struct process. */ void process_destroy(struct process *proc); /* Initialize argv of struct process. */ /* Return 1 if OK, 0 for errors. */ int process_argv_init_by_array(struct process *proc, int size, char**array); /* Destroy argv of struct process. */ /* void process_argv_destroy(struct process *proc); */ /* Print cmdline of process. */ void process_print_cmdline(struct process *proc); /* Print names of process. */ void process_print_names(struct process *proc); /* Print structure of process. */ void process_print_struct(struct process *proc); /* Close second sides of pipes. */ void process_close_2nd_sides_of_pipes(struct process *proc); #endif /* #ifndef _PROCESS_H */