-
- ipv = ( strchr( psz_destination, ':' ) != NULL ) ? '6' : '4';
-
- p = psz_sdp = malloc( i_size );
- p += sprintf( p, "v=0\r\n" );
- p += sprintf( p, "o=- "I64Fu" %d IN IP%c %s\r\n",
- p_sys->i_sdp_id, p_sys->i_sdp_version,
- ipv, ipv == '6' ? "::1" : "127.0.0.1" );
- if( *p_sys->psz_session_name )
- p += sprintf( p, "s=%s\r\n", p_sys->psz_session_name );
- if( *p_sys->psz_session_description )
- p += sprintf( p, "i=%s\r\n", p_sys->psz_session_description );
- if( *p_sys->psz_session_url )
- p += sprintf( p, "u=%s\r\n", p_sys->psz_session_url );
- if( *p_sys->psz_session_email )
- p += sprintf( p, "e=%s\r\n", p_sys->psz_session_email );
-
- p += sprintf( p, "t=0 0\r\n" ); /* permanent stream */ /* when scheduled from vlm, we should set this info correctly */
- p += sprintf( p, "a=tool:"PACKAGE_STRING"\r\n" );
- p += sprintf( p, "a=recvonly\r\n" );
- p += sprintf( p, "a=type:broadcast\r\n" );
-
- p += sprintf( p, "c=IN IP%c %s", ipv, psz_destination );
-
- if( ( ipv == 4 )
- && net_AddressIsMulticast( (vlc_object_t *)p_stream, psz_destination ) )