diff options
author | axel <axel@liljencrantz.se> | 2006-05-15 08:29:05 +1000 |
---|---|---|
committer | axel <axel@liljencrantz.se> | 2006-05-15 08:29:05 +1000 |
commit | 5a7a264b961210579222febe680e09cf0f39a08b (patch) | |
tree | 59e650a7c87cfdb5c1de09c5e5a06d350e90a714 /io.c | |
parent | 3d601bd75179e579bd76617c85f67c7fe0fca2f7 (diff) |
Fix bug that caused block level io redirection to break on while loops
darcs-hash:20060514222905-ac50b-7dec0ed716f5fe6af9069b597eee464829a8d820.gz
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 17 |
1 files changed, 7 insertions, 10 deletions
@@ -213,37 +213,34 @@ io_data_t *io_get( io_data_t *io, int fd ) return 0; } -/* -static void io_print( io_data_t *io ) + +void io_print( io_data_t *io ) { if( !io ) { - fwprintf( stderr, L"\n" ); return; } - - fwprintf( stderr, L"IO fd %d, type ", + debug( 1, L"IO fd %d, type ", io->fd ); switch( io->io_mode ) { case IO_PIPE: - fwprintf(stderr, L"PIPE, data %d\n", io->pipe_fd[io->fd?1:0] ); + debug( 1, L"PIPE, data %d", io->param1.pipe_fd[io->fd?1:0] ); break; case IO_FD: - fwprintf(stderr, L"FD, copy %d\n", io->old_fd ); + debug( 1, L"FD, copy %d", io->param1.old_fd ); break; case IO_BUFFER: - fwprintf( stderr, L"BUFFER\n" ); + debug( 1, L"BUFFER" ); break; default: - fwprintf( stderr, L"OTHER\n" ); + debug( 1, L"OTHER" ); } io_print( io->next ); } -*/ |