Mercurial > hg > octave-lyh
comparison scripts/plot/__gnuplot_open_stream__.m @ 11588:d5bd2766c640
style fixes for warning and error messages in script files
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 20 Jan 2011 17:51:13 -0500 |
parents | c792872f8942 |
children |
comparison
equal
deleted
inserted
replaced
11587:c792872f8942 | 11588:d5bd2766c640 |
---|---|
27 function plot_stream = __gnuplot_open_stream__ (npipes, h) | 27 function plot_stream = __gnuplot_open_stream__ (npipes, h) |
28 [prog, args] = gnuplot_binary (); | 28 [prog, args] = gnuplot_binary (); |
29 if (npipes > 1) | 29 if (npipes > 1) |
30 [plot_stream(1), plot_stream(2), pid] = popen2 (prog, args{:}); | 30 [plot_stream(1), plot_stream(2), pid] = popen2 (prog, args{:}); |
31 if (pid < 0) | 31 if (pid < 0) |
32 error ("__gnuplot_open_stream__: failed to open connection to gnuplot."); | 32 error ("__gnuplot_open_stream__: failed to open connection to gnuplot"); |
33 else | 33 else |
34 plot_stream(3) = pid; | 34 plot_stream(3) = pid; |
35 endif | 35 endif |
36 else | 36 else |
37 plot_stream = popen (sprintf ("%s ", prog, args{:}), "w"); | 37 plot_stream = popen (sprintf ("%s ", prog, args{:}), "w"); |
38 if (plot_stream < 0) | 38 if (plot_stream < 0) |
39 error ("__gnuplot_open_stream__: failed to open connection to gnuplot."); | 39 error ("__gnuplot_open_stream__: failed to open connection to gnuplot"); |
40 endif | 40 endif |
41 endif | 41 endif |
42 if (nargin > 1) | 42 if (nargin > 1) |
43 set (h, "__plot_stream__", plot_stream); | 43 set (h, "__plot_stream__", plot_stream); |
44 endif | 44 endif |