gst bug, first round

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

gst bug, first round

Paolo Bonzini
This pretty trivial patch is enough for "gst pipe.st" to work (i.e.
input from a tty) when pipe.st is

   | line |
   [ stdin atEnd ]
     whileFalse: [ stdout nextPutAll: stdin nextLine; nl; flush ] !

Linux resets pfd.revents on its own, but that's not portable.  With this
patch, at least the stream is not closed.  But #atEnd is still not
working correctly on pipes :-( so it is not enough if I remove the
flush, and it is not enough for "cat ~/.profile | gst pipe.st", I'll
take a look on the next train ride to Lugano...

--- orig/libgst/events.c
+++ mod/libgst/events.c
@@ -155,6 +155,7 @@ _gst_sync_file_polling (int fd,
   do
     {
       errno = 0;
+      pfd.revents = 0;
       result = poll (&pfd, 1, 0);
     }
   while ((result == -1) && (errno == EINTR));

Paolo


_______________________________________________
help-smalltalk mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-smalltalk