$pid = open (OUT, "| mplayer /Server/video/video.avi 2>/dev/null 1>/dev/null ") or die "geht nicht"; OUT->autoflush(1); while (!waitpid($pid,WNOHANG)) { $|=1; vec( my $in, fileno(STDIN), 1 ) = 1; if ( select( $in, undef, undef, 1 ) ) { my $input = ; print OUT "$input"; } } close OUT;