diff options
author | ridiculousfish <corydoras@ridiculousfish.com> | 2012-02-09 18:43:36 -0800 |
---|---|---|
committer | ridiculousfish <corydoras@ridiculousfish.com> | 2012-02-09 18:43:36 -0800 |
commit | e5ff5f7484c0e751172a2cab65d6d88a68ef281d (patch) | |
tree | ab384fbf6216fa62a602fab569a6ffc47d629fa6 /io.h | |
parent | 646240fc54617d39e0768d256a15eda94ee52812 (diff) |
Some hopefully good changes to get IOs off of halloc
Diffstat (limited to 'io.h')
-rw-r--r-- | io.h | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -11,7 +11,7 @@ enum io_mode ; /** Represents an FD redirection */ -typedef struct io_data +struct io_data_t { /** Type of redirect */ int io_mode; @@ -41,8 +41,7 @@ typedef struct io_data buffer_t *out_buffer; /** Whether to close old_fd for IO_FD */ int close_old; - } param2 - ; + } param2; /** Set to true if this is an input io redirection @@ -50,9 +49,10 @@ typedef struct io_data int is_input; /** Pointer to the next IO redirection */ - struct io_data *next; -} -io_data_t; + io_data_t *next; + + io_data_t() : next(NULL) { } +}; /** @@ -66,9 +66,9 @@ io_data_t *io_add( io_data_t *first_chain, io_data_t *decond_chain ); io_data_t *io_remove( io_data_t *list, io_data_t *element ); /** - Make a copy of the specified chain of redirections. Uses halloc. + Make a copy of the specified chain of redirections. Uses operator new. */ -io_data_t *io_duplicate( void *context, io_data_t *l ); +io_data_t *io_duplicate( io_data_t *l ); /** Return the last io redirection in the chain for the specified file descriptor. |