Re: popen() works, but now?
- From: "Timothy M. Shead" <tshead k-3d com>
- To: Ronald Bultje <rbultje ronald bitfreak net>
- Cc: gtk-list gnome org
- Subject: Re: popen() works, but now?
- Date: Thu, 18 Jan 2001 04:04:01 -0800
Ronald Bultje wrote:
Hi again,
I learned to use FILE *some_pipe = popen(command,"w"); to open a program
and write some data to it's stdin. The program receives the data I send to
it (press enter to continue -> fprintf(some_pipe, "\n");, for example), but
for some reason, this takes effect *after* I close my main application.
Should I make this a thread or something? It is supposed to receive and
process this data *while* the main application is running.
I believe the output from fprintf is buffered - you probably need to
flush the stream:
fflush(some_pipe);
Regards,
Timothy M. Shead
tshead k-3d com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]