18 lines
345 B
C
18 lines
345 B
C
#ifndef REDIRECTION_H
|
|
#define REDIRECTION_H
|
|
|
|
#define REDIRECT_NONE 0
|
|
#define REDIRECT_IN 1
|
|
#define REDIRECT_OUT 2
|
|
#define REDIRECT_APPEND 3
|
|
|
|
typedef struct {
|
|
int type;
|
|
char *filename;
|
|
} Redirection;
|
|
|
|
void detectRedirections(char **args, Redirection *in, Redirection *out);
|
|
int applyRedirections(Redirection in, Redirection out);
|
|
|
|
#endif
|