lightful / DVBdirect

DVB easy handling tools for Linux
GNU General Public License v3.0
13 stars 6 forks source link

If I specify the output file as /dev/stdout, dvbjet seems to not flush the output #1

Open YoshiWalsh opened 5 years ago

YoshiWalsh commented 5 years ago

I'm trying to read the output of dvbjet into a NodeJS script. I'm using Node's child_process to launch dvbjet, and I'm specifying /dev/stdout as the output file on the dvbjet command line.

My NodeJS script never receives any data from dvbjet's stdout. I suspect the data is being buffered. If I use node-pty instead of child_process then I receive output, but as node-pty converts all output to a string the data is corrupted.

I'm wondering if it's possible to make dvbjet correctly flush stdout if /dev/stdout is specified as the output filename. I've tried a few things myself, but I don't know c++ so I'm not having much luck.

phpbg commented 5 years ago

Hi, thats weird. I'm using dvbjet /dev/stdout in this PHP TV project and I receive correctly the output.

It doesn't seem to be a dvbdirect/dvbjet issue...