+ if( p_sys->arib.e_mode == ARIBMODE_ENABLED )
+ {
+ if( p_sys->i_tdt_delta == 0 )
+ p_sys->i_tdt_delta = CLOCK_FREQ * (i_start + i_duration - 5) - mdate();
+
+ //i_start -= 9 * 60 * 60; // JST -> UTC
+ time_t timer = time( NULL );
+ int64_t diff = difftime( mktime( localtime( &timer ) ),
+ mktime( gmtime( &timer ) ) );
+ i_start -= diff;
+ i_tot_time = (mdate() + p_sys->i_tdt_delta) / CLOCK_FREQ - diff;
+
+ if( p_evt->i_running_status == 0x00 &&
+ (i_start - 5 < i_tot_time &&
+ i_tot_time < i_start + i_duration + 5) )
+ {
+ p_evt->i_running_status = 0x04;
+ msg_Dbg( p_demux, " EIT running status 0x00 -> 0x04" );
+ }
+ }
+