socket_error_is_ignorable can cause infinite loop in gstmultiudpsink.c if RTSP client connection is lost and EOS is sent to pipeline for gst-rtsp-server

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

socket_error_is_ignorable can cause infinite loop in gstmultiudpsink.c if RTSP client connection is lost and EOS is sent to pipeline for gst-rtsp-server

krakorar
socket_error_is_ignorable can cause infinite loop in gstmultiudpsink.c
if RTSP client connection is lost and EOS is sent to pipeline for
gst-rtsp-server.  The remedy is to add ECONNREFUSED to the
conditional.

static gboolean
socket_error_is_ignorable (void)
{
#ifdef G_OS_WIN32
  /* Windows doesn't seem to have an EAGAIN for sockets */
  return WSAGetLastError () == WSAEINTR || WSAGetLastError() == WSAECONNREFUSED;
#else
  return errno == EINTR || errno == EAGAIN || errno == ECONNREFUSED;
#endif
}

--
Rob Krakora
Senior Software Engineer
MessageNet Systems
101 East Carmel Dr. Suite 105
Carmel, IN 46032
(317)566-1677 Ext. 206
(317)663-0808 Fax

------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: socket_error_is_ignorable can cause infinite loop in gstmultiudpsink.c if RTSP client connection is lost and EOS is sent to pipeline for gst-rtsp-server

Stefan Sauer
Am 29.07.2010 17:49, schrieb Robert Krakora:

> socket_error_is_ignorable can cause infinite loop in gstmultiudpsink.c
> if RTSP client connection is lost and EOS is sent to pipeline for
> gst-rtsp-server.  The remedy is to add ECONNREFUSED to the
> conditional.
>
> static gboolean
> socket_error_is_ignorable (void)
> {
> #ifdef G_OS_WIN32
>   /* Windows doesn't seem to have an EAGAIN for sockets */
>   return WSAGetLastError () == WSAEINTR || WSAGetLastError() == WSAECONNREFUSED;
> #else
>   return errno == EINTR || errno == EAGAIN || errno == ECONNREFUSED;
> #endif
> }
>
please file a bug + patch.

thanks,

Stefan

------------------------------------------------------------------------------
This SF.net email is sponsored by

Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev 
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel