while( !p_access->b_die )
{
+ msg_Warn( p_access, "GetPacket 1" );
if( GetPacket( p_access, &ck ) )
break;
else
{
chunk_t ck;
+ msg_Warn( p_access, "GetPacket 2" );
if( GetPacket( p_access, &ck ) )
{
int i_ret = -1;
if( Describe( p_access, &psz_location ) )
{
msg_Err( p_access, "describe failed" );
- return VLC_ENGENERIC;
+ return VLC_EGENERIC;
}
/* */
if( Start( p_access, 0 ) )
{
msg_Err( p_access, "Start failed" );
- return VLC_ENGENERIC;
+ return VLC_EGENERIC;
}
return VLC_SUCCESS;
}
/* Get the next header FIXME memory loss ? */
GetHeader( p_access );
if( p_sys->i_header <= 0 )
- return VLC_ENGENERIC;
+ return VLC_EGENERIC;
E_( asf_HeaderParse )( &p_sys->asfh,
p_sys->p_header, p_sys->i_header );
/*****************************************************************************
* Start stream
- *****************************************************************************/
+ ****************************************************************************/
static int Start( access_t *p_access, off_t i_pos )
{
access_sys_t *p_sys = p_access->p_sys;
}
}
net_Printf( VLC_OBJECT(p_access), p_sys->fd, NULL, "\r\n" );
+#if 0
net_Printf( VLC_OBJECT(p_access), p_sys->fd, NULL,
"Connection: Close\r\n" );
msg_Err( p_access, "failed to send request" );
return VLC_EGENERIC;
}
+#endif
psz = net_Gets( VLC_OBJECT(p_access), p_sys->fd, NULL );
if( psz == NULL )
{
- msg_Err( p_access, "cannot read data" );
+ msg_Err( p_access, "cannot read data 0" );
return VLC_EGENERIC;
}
char *psz = net_Gets( p_access, p_sys->fd, NULL );
if( psz == NULL )
{
- msg_Err( p_access, "cannot read data" );
+ msg_Err( p_access, "cannot read data 1" );
return VLC_EGENERIC;
}
if( *psz == '\0' )
* entire header.
*/
if( net_Read( p_access, p_sys->fd, NULL, p_sys->buffer, 4, VLC_TRUE ) < 4 )
+ {
+ msg_Err( p_access, "cannot read data 2" );
return VLC_EGENERIC;
+ }
p_ck->i_type = GetWLE( p_sys->buffer);
p_ck->i_size = GetWLE( p_sys->buffer + 2);
if( net_Read( p_access, p_sys->fd, NULL, p_sys->buffer + 4, restsize, VLC_TRUE ) < restsize )
{
- msg_Err( p_access, "cannot read data" );
+ msg_Err( p_access, "cannot read data 3" );
return VLC_EGENERIC;
}
p_ck->i_sequence = GetDWLE( p_sys->buffer + 4);
(net_Read( p_access, p_sys->fd, NULL, &p_sys->buffer[12],
p_ck->i_data, VLC_TRUE ) < p_ck->i_data) )
{
- msg_Err( p_access, "cannot read data" );
+ msg_Err( p_access, "cannot read data 4" );
return VLC_EGENERIC;
}