Colin Walters
0e1a3ee345
gsubprocess: Fix up communicate
...
We weren't closing the streams after we were done reading or writing,
which is kind of essential. The easy way to fix this is to just use
g_output_stream_splice() to a GMemoryOutputStream rather than
hand-rolling it. This results in a substantial reduction of code
complexity.
A second serious issue is that we were marking the task as complete when
the process exits, but that's racy - there could still be data to read
from stdout. Fix this by just refcounting outstanding operations.
This code, not surprisingly, looks a lot like the "multi" test.
Next, because processes output binary data, I'd be forced to annotate
the char*/length pairs as (array) (element-type uint8). But rather than
doing that, it's *far* simpler to just use GBytes.
We need a version of this that actually validates as UTF-8, that will be
in the next patch.
2013-10-17 14:32:44 -04:00
..
2013-05-20 06:38:41 -04:00
2013-05-31 23:12:15 -04:00
2011-11-07 00:14:28 -05:00
2012-12-28 21:28:28 -05:00
2013-10-17 14:32:44 -04:00
2013-07-11 12:35:45 -04:00
2010-07-05 00:56:12 -04:00
2013-07-11 13:49:20 -04:00
2010-07-04 20:51:06 -04:00
2010-07-04 20:51:06 -04:00
2013-05-31 23:03:19 -04:00
2012-08-19 02:23:32 -04:00
2013-05-31 23:12:15 -04:00
2012-10-16 09:39:24 -04:00
2013-09-29 17:48:40 -04:00
2012-06-04 06:04:28 -04:00
2013-01-16 10:17:15 -05:00
2013-06-02 01:41:09 -04:00
2012-10-16 09:39:24 -04:00
2013-09-12 14:40:24 -04:00
2013-05-29 09:03:32 -04:00
2013-06-02 01:41:50 -04:00
2013-10-04 09:51:31 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-07-11 15:49:28 -04:00
2010-04-17 01:48:05 -04:00
2013-07-11 12:48:08 -04:00
2012-10-16 09:39:24 -04:00
2010-06-16 18:17:53 -04:00
2013-06-02 09:53:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-01-16 10:17:15 -05:00
2013-06-02 01:43:13 -04:00
2012-10-16 09:39:24 -04:00
2013-06-02 01:42:28 -04:00
2011-12-08 18:05:15 -05:00
2012-10-16 09:39:24 -04:00
2012-01-25 16:15:18 -05:00
2010-11-02 23:02:05 -04:00
2012-10-16 09:39:24 -04:00
2010-11-02 23:02:05 -04:00
2013-05-29 09:03:31 -04:00
2013-02-13 20:42:58 +00:00
2013-01-04 21:36:37 +01:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-05-29 09:03:31 -04:00
2013-05-29 09:03:32 -04:00
2013-05-29 09:03:32 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-05-31 23:12:15 -04:00
2013-05-31 23:12:15 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2010-06-11 18:21:27 -04:00
2012-10-16 09:39:24 -04:00
2013-05-21 11:23:22 -03:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-05-13 12:10:52 -04:00
2013-07-01 23:36:30 -04:00
2013-05-29 09:03:32 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-05-21 11:23:22 -03:00
2013-05-31 21:24:21 -04:00
2012-11-01 20:12:02 -04:00
2013-10-04 09:51:31 -04:00
2012-10-16 09:39:24 -04:00
2013-05-29 09:03:32 -04:00
2013-05-29 09:03:32 -04:00
2013-05-21 11:23:22 -03:00
2012-04-19 10:07:39 +02:00
2012-04-19 10:07:39 +02:00
2013-05-21 11:23:22 -03:00
2013-05-31 23:12:15 -04:00
2013-02-03 10:21:20 -05:00
2013-05-21 11:23:22 -03:00
2013-01-03 13:14:26 -05:00
2013-05-29 09:03:31 -04:00
2013-09-23 16:31:40 -04:00
2013-06-02 01:44:15 -04:00
2013-05-31 23:16:00 -04:00
2013-06-02 20:02:06 -04:00
2013-10-17 14:32:44 -04:00
2013-10-17 14:32:44 -04:00
2012-08-21 13:30:02 +02:00
2011-07-27 16:23:33 -04:00
2013-04-16 13:24:26 +02:00
2011-08-04 08:54:55 +02:00
2012-10-16 09:39:24 -04:00
2013-08-19 12:15:36 -04:00
2012-10-16 09:39:24 -04:00
2013-03-13 09:41:09 -04:00
2009-07-05 22:49:24 -04:00
2013-10-17 14:32:44 -04:00
2013-06-02 01:44:49 -04:00
2013-06-01 18:51:25 -04:00
2013-06-02 01:46:21 -04:00
2013-06-02 20:02:06 -04:00
2013-09-09 23:57:30 +02:00
2012-10-16 09:39:24 -04:00
2011-11-17 14:03:39 +00:00
2013-07-14 11:36:45 -04:00
2012-08-19 02:24:04 -04:00
2012-10-16 09:39:24 -04:00
2012-11-09 09:23:01 -08:00
2013-05-05 16:50:43 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-01-14 23:31:59 -05:00
2013-05-29 09:03:32 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2013-02-14 10:24:14 -05:00
2012-10-16 09:39:24 -04:00
2013-04-23 14:36:07 -04:00
2012-10-16 09:39:24 -04:00
2012-02-03 12:58:53 -05:00
2012-10-16 09:39:24 -04:00
2013-08-31 11:40:44 -04:00
2012-10-16 09:39:24 -04:00
2013-08-15 12:43:57 -04:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-01-13 17:12:53 +01:00
2012-10-03 11:23:04 -04:00
2011-11-21 18:15:26 +00:00
2011-11-21 18:15:26 +00:00
2012-11-02 09:03:52 -04:00
2011-11-21 18:15:26 +00:00
2012-01-25 14:47:37 +01:00
2010-07-01 19:06:02 -04:00
2013-05-29 09:03:32 -04:00
2012-10-16 09:39:24 -04:00
2012-12-12 15:20:22 +01:00
2013-06-02 01:47:19 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00
2012-10-16 09:39:24 -04:00