|
myshell 2.0.0
|
Structure representing a single redirection. More...
#include <msh_redirect.h>
Public Types | |
| enum | { NONE , OUT , OUT_APPEND , IN } |
Public Member Functions | |
| redirect (const Token &redirect_token) | |
| int | do_redirect (std::vector< int > *fd_to_close) const |
| Opens the redirectees with respect to the redirection type and duplicates the appropriate file descriptors. | |
Public Attributes | |
| struct redirectee | in |
| struct redirectee | out |
| bool | both_err_out = false |
| enum redirect:: { ... } | type = NONE |
Structure representing a single redirection.
Holds two redirectees and the type of the redirection.
|
inline |
Opens the redirectees with respect to the redirection type and duplicates the appropriate file descriptors.
The fd_to_close vector is populated with any file descriptors that were opened during the redirection process.
| fd_to_close | A vector of file descriptors to close. |