Commit 40669b1f authored by Thomas Guillem's avatar Thomas Guillem

ftp: fix pf_readdir infinite loop

parent 41de2a23
......@@ -861,13 +861,13 @@ static input_item_t* DirRead( access_t *p_access )
assert( p_sys->data.fd != -1 );
assert( !p_sys->out );
for( ;;)
{
char *psz_line;
if( p_sys->data.p_tls != NULL )
psz_line = vlc_tls_GetLine( p_sys->data.p_tls );
else
psz_line = net_Gets( p_access, p_sys->data.fd );
if( psz_line == NULL )
return NULL;
char *psz_uri;
if( asprintf( &psz_uri, "%s://%s:%d%s%s/%s",
......@@ -883,7 +883,6 @@ static input_item_t* DirRead( access_t *p_access )
free( psz_uri );
}
free( psz_line );
}
return p_item;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment