X-Git-Url: https://sigrok.org/gitweb/?p=sigrok-cli.git;a=blobdiff_plain;f=sigrok-cli.c;h=a1cb674bcd90ede392b4693dc8e971ef792f8094;hp=3bda15857377cb9f4c7546a08001eb9f6d797eec;hb=e09810e97db06458814a9e19e78988e7f1515c9e;hpb=48f71481bfa1011fd5c1538a0a8d467e0fe615a8 diff --git a/sigrok-cli.c b/sigrok-cli.c index 3bda158..a1cb674 100644 --- a/sigrok-cli.c +++ b/sigrok-cli.c @@ -583,6 +583,7 @@ static void datafeed_in(struct sr_dev *dev, struct sr_datafeed_packet *packet) o->format->data(o, filter_out, filter_out_len, &output_buf, &output_len); if (output_buf) { fwrite(output_buf, 1, output_len, outfile); + fflush(outfile); g_free(output_buf); } } @@ -638,6 +639,7 @@ static void datafeed_in(struct sr_dev *dev, struct sr_datafeed_packet *packet) &output_buf, &output_len); if (output_buf) { fwrite(output_buf, 1, output_len, outfile); + fflush(outfile); g_free(output_buf); } } @@ -652,6 +654,7 @@ static void datafeed_in(struct sr_dev *dev, struct sr_datafeed_packet *packet) &output_len); if (output_buf) { fwrite(output_buf, 1, output_len, outfile); + fflush(outfile); g_free(output_buf); } } @@ -664,6 +667,7 @@ static void datafeed_in(struct sr_dev *dev, struct sr_datafeed_packet *packet) &output_len); if (output_buf) { fwrite(output_buf, 1, output_len, outfile); + fflush(outfile); g_free(output_buf); } } @@ -923,6 +927,7 @@ void show_pd_annotations(struct srd_proto_data *pdata, void *cb_data) for (i = 0; annotations[i]; i++) printf("\"%s\" ", annotations[i]); printf("\n"); + fflush(stdout); } static int select_probes(struct sr_dev *dev)