Commit 92ec47e1 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

Fix build when using C++11

parent d36bc0a7
......@@ -307,7 +307,7 @@ static int Open ( vlc_object_t *p_this )
p_demux->p_sys = p_sys = (demux_sys_t*)calloc( 1, sizeof( demux_sys_t ) );
if( !p_sys ) return VLC_ENOMEM;
msg_Dbg( p_demux, "version "LIVEMEDIA_LIBRARY_VERSION_STRING );
msg_Dbg( p_demux, "version " LIVEMEDIA_LIBRARY_VERSION_STRING );
TAB_INIT( p_sys->i_track, p_sys->track );
p_sys->f_npt = 0.;
......@@ -591,7 +591,7 @@ createnew:
p_sys->rtsp = new RTSPClientVlc( *p_sys->env, psz_url,
var_InheritInteger( p_demux, "verbose" ) > 1 ? 1 : 0,
"LibVLC/"VERSION, i_http_port, p_sys );
"LibVLC/" VERSION, i_http_port, p_sys );
if( !p_sys->rtsp )
{
msg_Err( p_demux, "RTSPClient::createNew failed (%s)",
......
......@@ -231,7 +231,7 @@ EbmlElement *EbmlParser::Get( int n_call )
m_el[mi_level]->GetEndPosition() <= m_el[mi_level-1]->GetEndPosition() ) )
{
/* The element fits inside its upper element */
msg_Warn( p_demux, "Dummy element found %"PRIu64"... skipping it",
msg_Warn( p_demux, "Dummy element found %" PRIu64 "... skipping it",
m_el[mi_level]->GetElementPosition() );
return Get( ++n_call );
}
......@@ -239,7 +239,7 @@ EbmlElement *EbmlParser::Get( int n_call )
{
/* Too large, misplaced or 10 successive dummy elements */
msg_Err( p_demux,
"Dummy element too large or misplaced at %"PRIu64"... skipping to next upper element",
"Dummy element too large or misplaced at %" PRIu64 "... skipping to next upper element",
m_el[mi_level]->GetElementPosition() );
if( mi_level >= 1 &&
......
......@@ -745,7 +745,7 @@ bool matroska_script_interpretor_c::Interpret( const binary * p_command, size_t
virtual_chapter_c *p_chapter = sys.FindChapter( i_chapter_uid, p_segment );
if ( p_chapter == NULL )
msg_Dbg( &sys.demuxer, "Chapter %"PRId64" not found", i_chapter_uid);
msg_Dbg( &sys.demuxer, "Chapter %" PRId64 " not found", i_chapter_uid);
else
{
if ( !p_chapter->EnterAndLeave( sys.p_current_segment->CurrentChapter() ) )
......
......@@ -493,7 +493,7 @@ matroska_stream_c *demux_sys_t::AnalyseAllSegmentsFound( demux_t *p_demux, EbmlS
EDocTypeReadVersion doc_read_version = GetChild<EDocTypeReadVersion>(*static_cast<EbmlHead*>(p_l0));
if (uint64(doc_read_version) > 2)
{
msg_Err( p_demux, "matroska file needs version %"PRId64" but only versions 1 & 2 supported", uint64(doc_read_version));
msg_Err( p_demux, "matroska file needs version %" PRId64 " but only versions 1 & 2 supported", uint64(doc_read_version));
return NULL;
}
......@@ -704,7 +704,7 @@ bool demux_sys_t::PreloadLinked()
SimpleTag * p_st = tags[k]->simple_tags[l];
if( !strcmp(p_st->psz_tag_name,"TITLE") )
{
msg_Dbg( &demuxer, "Using title \"%s\" from tag for edition %"PRIu64, p_st->p_value, i_ed_uid );
msg_Dbg( &demuxer, "Using title \"%s\" from tag for edition %" PRIu64, p_st->p_value, i_ed_uid );
p_title->psz_name = strdup( p_st->p_value );
break;
}
......
......@@ -427,7 +427,7 @@ void matroska_segment_c::LoadTags( KaxTags *tags )
KaxTagTrackUID &uid = *(KaxTagTrackUID*) el;
uid.ReadData( es.I_O() );
p_tag->i_uid = uint64( uid );
msg_Dbg( &sys.demuxer, "| | + TrackUID: %"PRIu64, p_tag->i_uid);
msg_Dbg( &sys.demuxer, "| | + TrackUID: %" PRIu64, p_tag->i_uid);
}
if( MKV_IS_ID( el, KaxTagEditionUID ) )
......@@ -436,7 +436,7 @@ void matroska_segment_c::LoadTags( KaxTags *tags )
KaxTagEditionUID &uid = *(KaxTagEditionUID*) el;
uid.ReadData( es.I_O() );
p_tag->i_uid = uint64( uid );
msg_Dbg( &sys.demuxer, "| | + EditionUID: %"PRIu64, p_tag->i_uid);
msg_Dbg( &sys.demuxer, "| | + EditionUID: %" PRIu64, p_tag->i_uid);
}
if( MKV_IS_ID( el, KaxTagChapterUID ) )
{
......@@ -444,7 +444,7 @@ void matroska_segment_c::LoadTags( KaxTags *tags )
KaxTagChapterUID &uid = *(KaxTagChapterUID*) el;
uid.ReadData( es.I_O() );
p_tag->i_uid = uint64( uid );
msg_Dbg( &sys.demuxer, "| | + ChapterUID: %"PRIu64, p_tag->i_uid);
msg_Dbg( &sys.demuxer, "| | + ChapterUID: %" PRIu64, p_tag->i_uid);
}
if( MKV_IS_ID( el, KaxTagAttachmentUID ) )
{
......@@ -452,7 +452,7 @@ void matroska_segment_c::LoadTags( KaxTags *tags )
KaxTagAttachmentUID &uid = *(KaxTagAttachmentUID*) el;
uid.ReadData( es.I_O() );
p_tag->i_uid = uint64( uid );
msg_Dbg( &sys.demuxer, "| | + AttachmentUID: %"PRIu64, p_tag->i_uid);
msg_Dbg( &sys.demuxer, "| | + AttachmentUID: %" PRIu64, p_tag->i_uid);
}
}
catch(...)
......@@ -927,7 +927,7 @@ void matroska_segment_c::Seek( mtime_t i_date, mtime_t i_time_offset, int64_t i_
i_seek_time = p_indexes[i_idx].i_time;
}
msg_Dbg( &sys.demuxer, "seek got %"PRId64" - %"PRId64, i_seek_time, i_seek_position );
msg_Dbg( &sys.demuxer, "seek got %" PRId64 " - %" PRId64, i_seek_time, i_seek_position );
es.I_O().setFilePointer( i_seek_position, seek_beginning );
......
......@@ -126,42 +126,42 @@ void matroska_segment_c::ParseSeekHead( KaxSeekHead *seekhead )
{
if( id == EBML_ID(KaxCues) )
{
msg_Dbg( &sys.demuxer, "| - cues at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - cues at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxCues), i_pos );
}
else if( id == EBML_ID(KaxInfo) )
{
msg_Dbg( &sys.demuxer, "| - info at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - info at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxInfo), i_pos );
}
else if( id == EBML_ID(KaxChapters) )
{
msg_Dbg( &sys.demuxer, "| - chapters at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - chapters at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxChapters), i_pos );
}
else if( id == EBML_ID(KaxTags) )
{
msg_Dbg( &sys.demuxer, "| - tags at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - tags at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxTags), i_pos );
}
else if( id == EBML_ID(KaxSeekHead) )
{
msg_Dbg( &sys.demuxer, "| - chained seekhead at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - chained seekhead at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxSeekHead), i_pos );
}
else if( id == EBML_ID(KaxTracks) )
{
msg_Dbg( &sys.demuxer, "| - tracks at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - tracks at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxTracks), i_pos );
}
else if( id == EBML_ID(KaxAttachments) )
{
msg_Dbg( &sys.demuxer, "| - attachments at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - attachments at %" PRId64, i_pos );
LoadSeekHeadItem( EBML_INFO(KaxAttachments), i_pos );
}
#ifdef MKV_DEBUG
else
msg_Dbg( &sys.demuxer, "| - unknown seekhead reference at %"PRId64, i_pos );
msg_Dbg( &sys.demuxer, "| - unknown seekhead reference at %" PRId64, i_pos );
#endif
}
}
......@@ -334,7 +334,7 @@ void matroska_segment_c::ParseTrackEntry( KaxTrackEntry *m )
KaxTrackDefaultDuration &defd = *(KaxTrackDefaultDuration*)l;
tk->i_default_duration = uint64(defd);
msg_Dbg( &sys.demuxer, "| | | + Track Default Duration=%"PRId64, uint64(defd) );
msg_Dbg( &sys.demuxer, "| | | + Track Default Duration=%" PRId64, uint64(defd) );
}
else if( MKV_IS_ID( l, KaxTrackTimecodeScale ) )
{
......@@ -383,7 +383,7 @@ void matroska_segment_c::ParseTrackEntry( KaxTrackEntry *m )
tk->p_extra_data = (uint8_t*)malloc( tk->i_extra_data );
memcpy( tk->p_extra_data, cpriv.GetBuffer(), tk->i_extra_data );
}
msg_Dbg( &sys.demuxer, "| | | + Track CodecPrivate size=%"PRId64, cpriv.GetSize() );
msg_Dbg( &sys.demuxer, "| | | + Track CodecPrivate size=%" PRId64, cpriv.GetSize() );
}
else if( MKV_IS_ID( l, KaxCodecName ) )
{
......@@ -410,14 +410,14 @@ void matroska_segment_c::ParseTrackEntry( KaxTrackEntry *m )
{
KaxCodecDelay &codecdelay = *(KaxCodecDelay*)l;
tk->i_codec_delay = uint64_t( codecdelay ) / 1000;
msg_Dbg( &sys.demuxer, "| | | + Track Codec Delay =%"PRIu64,
msg_Dbg( &sys.demuxer, "| | | + Track Codec Delay =%" PRIu64,
tk->i_codec_delay );
}
else if( MKV_IS_ID( l, KaxSeekPreRoll ) )
{
KaxSeekPreRoll &spr = *(KaxSeekPreRoll*)l;
tk->i_seek_preroll = uint64_t(spr) / 1000;
msg_Dbg( &sys.demuxer, "| | | + Track Seek Preroll =%"PRIu64, tk->i_seek_preroll );
msg_Dbg( &sys.demuxer, "| | | + Track Seek Preroll =%" PRIu64, tk->i_seek_preroll );
}
#endif
else if( MKV_IS_ID( l, KaxContentEncodings ) )
......@@ -837,7 +837,7 @@ void matroska_segment_c::ParseInfo( KaxInfo *info )
i_timescale = uint64(tcs);
msg_Dbg( &sys.demuxer, "| | + TimecodeScale=%"PRId64,
msg_Dbg( &sys.demuxer, "| | + TimecodeScale=%" PRId64,
i_timescale );
}
else if( MKV_IS_ID( l, KaxDuration ) )
......@@ -846,7 +846,7 @@ void matroska_segment_c::ParseInfo( KaxInfo *info )
i_duration = mtime_t( double( dur ) );
msg_Dbg( &sys.demuxer, "| | + Duration=%"PRId64,
msg_Dbg( &sys.demuxer, "| | + Duration=%" PRId64,
i_duration );
}
else if( MKV_IS_ID( l, KaxMuxingApp ) )
......@@ -972,7 +972,7 @@ void matroska_segment_c::ParseChapterAtom( int i_level, KaxChapterAtom *ca, chap
if( MKV_IS_ID( l, KaxChapterUID ) )
{
chapters.i_uid = uint64_t(*(KaxChapterUID*)l);
msg_Dbg( &sys.demuxer, "| | | | + ChapterUID: %"PRIu64"", chapters.i_uid );
msg_Dbg( &sys.demuxer, "| | | | + ChapterUID: %" PRIu64, chapters.i_uid );
}
else if( MKV_IS_ID( l, KaxChapterFlagHidden ) )
{
......@@ -1003,14 +1003,14 @@ void matroska_segment_c::ParseChapterAtom( int i_level, KaxChapterAtom *ca, chap
KaxChapterTimeStart &start =*(KaxChapterTimeStart*)l;
chapters.i_start_time = uint64( start ) / INT64_C(1000);
msg_Dbg( &sys.demuxer, "| | | | + ChapterTimeStart: %"PRId64"", chapters.i_start_time );
msg_Dbg( &sys.demuxer, "| | | | + ChapterTimeStart: %" PRId64, chapters.i_start_time );
}
else if( MKV_IS_ID( l, KaxChapterTimeEnd ) )
{
KaxChapterTimeEnd &end =*(KaxChapterTimeEnd*)l;
chapters.i_end_time = uint64( end ) / INT64_C(1000);
msg_Dbg( &sys.demuxer, "| | | | + ChapterTimeEnd: %"PRId64"", chapters.i_end_time );
msg_Dbg( &sys.demuxer, "| | | | + ChapterTimeEnd: %" PRId64, chapters.i_end_time );
}
else if( MKV_IS_ID( l, KaxChapterDisplay ) )
{
......
......@@ -411,7 +411,7 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
case DEMUX_SET_TIME:
i64 = (int64_t) va_arg( args, int64_t );
msg_Dbg(p_demux,"SET_TIME to %"PRId64, i64 );
msg_Dbg(p_demux,"SET_TIME to %" PRId64, i64 );
Seek( p_demux, i64, -1, NULL );
return VLC_SUCCESS;
default:
......@@ -430,7 +430,7 @@ static void Seek( demux_t *p_demux, mtime_t i_date, double f_percent, virtual_ch
int i_index;
msg_Dbg( p_demux, "seek request to %"PRId64" (%f%%)", i_date, f_percent );
msg_Dbg( p_demux, "seek request to %" PRId64 " (%f%%)", i_date, f_percent );
if( i_date < 0 && f_percent < 0 )
{
msg_Warn( p_demux, "cannot seek nowhere!" );
......@@ -460,7 +460,7 @@ static void Seek( demux_t *p_demux, mtime_t i_date, double f_percent, virtual_ch
{
int64_t i_pos = int64_t( f_percent * stream_Size( p_demux->s ) );
msg_Dbg( p_demux, "lengthy way of seeking for pos:%"PRId64, i_pos );
msg_Dbg( p_demux, "lengthy way of seeking for pos:%" PRId64, i_pos );
for( i_index = 0; i_index < p_segment->i_index; i_index++ )
{
if( p_segment->p_indexes[i_index].i_position >= i_pos &&
......@@ -472,7 +472,7 @@ static void Seek( demux_t *p_demux, mtime_t i_date, double f_percent, virtual_ch
if( p_segment->p_indexes[i_index].i_position < i_pos )
{
msg_Dbg( p_demux, "no cues, seek request to global pos: %"PRId64, i_pos );
msg_Dbg( p_demux, "no cues, seek request to global pos: %" PRId64, i_pos );
i_global_position = i_pos;
}
}
......
......@@ -88,7 +88,7 @@ virtual_chapter_c * virtual_chapter_c::CreateVirtualChapter( chapter_item_c * p_
*usertime_offset = tmp;
msg_Dbg( &p_main_segment->sys.demuxer,
"Virtual chapter %s from %"PRId64" to %"PRId64" - " ,
"Virtual chapter %s from %" PRId64 " to %" PRId64 " - " ,
p_chap->psz_name.c_str(), p_vchap->i_virtual_start_time, p_vchap->i_virtual_stop_time );
return p_vchap;
......@@ -409,7 +409,7 @@ bool virtual_segment_c::UpdateCurrentToChapter( demux_t & demux )
/* we have moved to a new chapter */
if ( p_cur_chapter != NULL && p_current_chapter != p_cur_chapter )
{
msg_Dbg( &demux, "NEW CHAPTER %"PRId64, sys.i_pts );
msg_Dbg( &demux, "NEW CHAPTER %" PRId64, sys.i_pts );
if ( p_cur_edition->b_ordered )
{
/* FIXME EnterAndLeave has probably been broken for a long time */
......
......@@ -1355,7 +1355,7 @@ static inline size_t mp4_box_headersize( MP4_Box_t *p_box )
if( i_actually_read < 0 || (int64_t)i_actually_read < i_read )\
{ \
msg_Warn( p_stream, "MP4_READBOX_ENTER: I got %i bytes, "\
"but I requested %"PRId64"", i_actually_read, i_read );\
"but I requested %" PRId64, i_actually_read, i_read );\
free( p_buff ); \
return( 0 ); \
} \
......
......@@ -40,10 +40,10 @@ static inline void vobsub_palette_rgb2yuv( uint32_t *pu_palette )
static inline int vobsub_palette_parse( const char *psz_buf, uint32_t *pu_palette )
{
if( sscanf( psz_buf, "palette: "
"%"PRIx32", %"PRIx32", %"PRIx32", %"PRIx32", "
"%"PRIx32", %"PRIx32", %"PRIx32", %"PRIx32", "
"%"PRIx32", %"PRIx32", %"PRIx32", %"PRIx32", "
"%"PRIx32", %"PRIx32", %"PRIx32", %"PRIx32"",
"%" PRIx32", %" PRIx32 ", %" PRIx32 ", %" PRIx32 ", "
"%" PRIx32", %" PRIx32 ", %" PRIx32 ", %" PRIx32 ", "
"%" PRIx32", %" PRIx32 ", %" PRIx32 ", %" PRIx32 ", "
"%" PRIx32", %" PRIx32 ", %" PRIx32 ", %" PRIx32 "",
&pu_palette[0], &pu_palette[1], &pu_palette[2], &pu_palette[3],
&pu_palette[4], &pu_palette[5], &pu_palette[6], &pu_palette[7],
&pu_palette[8], &pu_palette[9], &pu_palette[10], &pu_palette[11],
......
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