{
block_fifo_t *p_fifo;
- int i_files;
- int i_file_size;
- int i_write_size;
+ unsigned i_files;
+ unsigned i_file_size;
+ unsigned i_write_size;
ts_entry_t *p_read_list;
ts_entry_t **pp_read_last;
access_t *p_access = (access_t*)p_this;
access_sys_t *p_sys = p_access->p_sys;
ts_entry_t *p_entry;
- int i;
+ unsigned i;
msg_Dbg( p_access, "timeshift close called" );
vlc_thread_join( p_access );
/* Put written file in read list */
if( p_sys->i_write_size < p_sys->i_file_size )
- ftruncate( fileno( p_sys->p_write_list->file ), p_sys->i_write_size );
+ if( ftruncate( fileno( p_sys->p_write_list->file ),
+ p_sys->i_write_size ) == -1 )
+ {
+ msg_Dbg( p_access, "unable to truncate file: %m" );
+ /* return; */
+ }
fseek( p_sys->p_write_list->file, 0, SEEK_SET );
*p_sys->pp_read_last = p_sys->p_write_list;
{
FILE *file;
- sprintf( p_sys->psz_filename, "%s%i.dat",
+ sprintf( p_sys->psz_filename, "%s%u.dat",
p_sys->psz_filename_base, p_sys->i_files );
file = utf8_fopen( p_sys->psz_filename, "w+b" );
static int Seek( access_t *p_access, int64_t i_pos )
{
//access_sys_t *p_sys = p_access->p_sys;
+ (void)p_access;
+ (void)i_pos;
return VLC_SUCCESS;
}