AW: Latest RTSPServer broken on windows >> workaround -

Matthias Dodt MDodt at xion-medical.com
Thu Oct 20 05:21:27 PDT 2011


Hi Jose!

We found a workaround for the RTSPServer problem on windows. Besides the changes mentioned before the following method gst_rtsp_source_chek(GSource * source) in gstrtspconnection.c (in plugins-base\gst-libs\gst\rtsp):
 
static gboolean
gst_rtsp_source_check (GSource * source)
{
  GstRTSPWatch *watch = (GstRTSPWatch *) source;
#ifdef G_OS_WIN32
  gboolean rv=FALSE;
  watch->readfd.revents=0;
  watch->writefd.revents=0;
  gst_poll_wait(watch->conn->fdset,0);
  if(gst_poll_fd_can_read(watch->conn->fdset,watch->conn->readfd)){
 watch->readfd.revents |= G_IO_IN;
 rv=TRUE;
  }
  if(gst_poll_fd_can_write(watch->conn->fdset,watch->conn->writefd)){
 watch->writefd.revents |= G_IO_OUT;
 rv=TRUE;
  }
  return rv;
#else
  if (watch->readfd.revents & READ_COND)
    return TRUE;
 
  if (watch->writefd.revents & WRITE_COND)
    return TRUE;
 
  return FALSE;
#end if

}
 
I am not sure if this is the best solution- would be nice if somebody could evaluate this approach and crosscheck if it works-
 
Thanks!
 
best,
 
mat



________________________________

Von: gstreamer-devel-bounces+mdodt=xion-medical.com at lists.freedesktop.org [mailto:gstreamer-devel-bounces+mdodt=xion-medical.com at lists.freedesktop.org] Im Auftrag von listas
Gesendet: 11 October 2011 19:47
An: gstreamer-devel at lists.freedesktop.org
Betreff: Re: Latest RTSPServer broken on windows


The problem is in glib. Don't allow multiple watches on the same socket and we have one for the server and another for each client.

https://bugzilla.gnome.org/show_bug.cgi?id=338943

Cheers,

Jose



El mar, 11-10-2011 a las 18:12 +0200, Matthias Dodt escribió: 

	Hi guys!
	
	It seems there is a problem with the latest GSTRTSPServer. It doesn't
	listen on a socket or establish a connection. Firstly in rtsp-server.c
	there is an ifdef missing (line 615...):
	
	gst_rtsp_server_get_io_channel(...){
	...
	/* create IO channel for the socket */
	#ifdef G_OS_WIN32
	  channel = g_io_channel_win32_new_socket (sockfd);
	#else
	  channel = g_io_channel_unix_new (sockfd);
	#endif
	...
	
	Then the client connects but the server doesn't react on the client's
	OPTIONS request. Any ideas? I guess it must be something with polling
	the socket.
	
	Cheers,
	
	mat
	_______________________________________________
	gstreamer-devel mailing list
	gstreamer-devel at lists.freedesktop.org
	http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20111020/f0efb8b1/attachment.html>


More information about the gstreamer-devel mailing list