- if( p_sys->p_input && p_sys->i_stream_start + 1500000 < mdate() )
- p_sys->p_input->b_eof = VLC_TRUE;
+ if( p_sys->i_stream_start + 1500000 < mdate() )
+ {
+ input_thread_t *p_input;
+
+ p_input = vlc_object_find( p_stream, VLC_OBJECT_INPUT, FIND_PARENT );
+ if( p_input )
+ {
+ p_input->b_eof = true;
+ vlc_object_release( p_input );
+ }
+ }