diff options
author | Daniel Baumann <mail@daniel-baumann.ch> | 2015-11-08 04:29:58 +0000 |
---|---|---|
committer | Daniel Baumann <mail@daniel-baumann.ch> | 2015-11-08 04:29:58 +0000 |
commit | 4646c2987eba0ba70050daf3c9fb450510a30237 (patch) | |
tree | b1312f8c64fd61a3097b553507d00cac44b3c4bd /zdiff.cc | |
parent | Adding debian version 1.1-1. (diff) | |
download | zutils-4646c2987eba0ba70050daf3c9fb450510a30237.tar.xz zutils-4646c2987eba0ba70050daf3c9fb450510a30237.zip |
Merging upstream version 1.2~pre2.
Signed-off-by: Daniel Baumann <mail@daniel-baumann.ch>
Diffstat (limited to 'zdiff.cc')
-rw-r--r-- | zdiff.cc | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -389,6 +389,11 @@ int main( const int argc, const char * const argv[] ) set_signals(); if( !set_fifonames( filenames ) ) return 2; + Children children[2]; + if( !set_data_feeder( fifonames[0], infd[0], children[0], format_types[0] ) || + !set_data_feeder( fifonames[1], infd[1], children[1], format_types[1] ) ) + return 2; + const pid_t diff_pid = fork(); if( diff_pid == 0 ) // child (diff) { @@ -407,11 +412,6 @@ int main( const int argc, const char * const argv[] ) if( diff_pid < 0 ) // parent { show_fork_error( DIFF ); return 2; } - Children children[2]; - if( !set_data_feeder( fifonames[0], infd[0], children[0], format_types[0] ) || - !set_data_feeder( fifonames[1], infd[1], children[1], format_types[1] ) ) - return 2; - int retval = wait_for_child( diff_pid, DIFF ); for( int i = 0; i < 2; ++i ) |