gst/udp/gstudpsrc.c: Fix possible infinite loop when shutting down, a read can also return 0 to indicate no more mess...

Original commit message from CVS:
Patch by: Antoine Tremblay <hexa00 at gmail dot com>
* gst/udp/gstudpsrc.c: (gst_udpsrc_create):
Fix possible infinite loop when shutting down, a read can also return
0 to indicate no more messages are available. Fixes #358156.
This commit is contained in:
Antoine Tremblay 2006-09-29 08:09:24 +00:00 committed by Wim Taymans
parent 210e3a8e67
commit 1a86fdc6e3
2 changed files with 9 additions and 1 deletions

View file

@ -1,3 +1,11 @@
2006-09-29 Wim Taymans <wim@fluendo.com>
Patch by: Antoine Tremblay <hexa00 at gmail dot com>
* gst/udp/gstudpsrc.c: (gst_udpsrc_create):
Fix possible infinite loop when shutting down, a read can also return
0 to indicate no more messages are available. Fixes #358156.
2006-09-25 Wim Taymans <wim@fluendo.com>
* gst/autodetect/gstautoaudiosink.c:

View file

@ -328,7 +328,7 @@ gst_udpsrc_create (GstPushSrc * psrc, GstBuffer ** buf)
int res;
READ_COMMAND (udpsrc, command, res);
if (res < 0) {
if (res <= 0) {
GST_LOG_OBJECT (udpsrc, "no more commands");
/* no more commands */
break;