Spawn.vala
[gitlive] / Spawn.vala
index e904817..36774b6 100644 (file)
@@ -1,7 +1,6 @@
 
 
 using GLib;
-using GString;
 // compile valac 
 
 /// # valac  --pkg gio-2.0  --pkg posix Spawn.vala -o /tmp/Spawn
@@ -401,10 +400,12 @@ public class Spawn : Object
         
         //print(JSON.stringify(ch, null,4));
         while (true) {
-            var buffer = new StringBuffer("");
-            
+            string buffer;
+            size_t term_pos;
+            size_t len;
+            IOStatus status;
             try {
-                var status = ch.read_line( buffer,  term_pos );
+                status = ch.read_line( out buffer,  out len,  out term_pos );
             } catch (Error e) {
                 //FIXme
                 break; // ??