From 63959d55d0e0c230449e87f6934a9b682a629b3c Mon Sep 17 00:00:00 2001 From: szabii Date: Mon, 23 Apr 2001 22:33:06 +0000 Subject: [PATCH] some warnings have gone git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@601 b3059339-0415-0410-9bf9-f77b7e298cf2 --- asfheader.c | 2 +- aviheader.c | 10 +++++----- demux_asf.c | 2 +- demux_avi.c | 14 +++++++------- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/asfheader.c b/asfheader.c index 55faa1404d..d0c58ae81f 100644 --- a/asfheader.c +++ b/asfheader.c @@ -120,7 +120,7 @@ if(verbose){ printf("stream type: %s\n",asf_chunk_type(streamh.type)); printf("stream concealment: %s\n",asf_chunk_type(streamh.concealment)); printf("type: %d bytes, stream: %d bytes ID: %d\n",(int)streamh.type_size,(int)streamh.stream_size,(int)streamh.stream_no); - printf("unk1: %lX unk2: %X\n",streamh.unk1,streamh.unk2); + printf("unk1: %lX unk2: %X\n",(unsigned long)streamh.unk1,(unsigned int)streamh.unk2); printf("FILEPOS=0x%X\n",stream_tell(demuxer->stream)); } // type-specific data: diff --git a/aviheader.c b/aviheader.c index 1538314222..f263a84e62 100644 --- a/aviheader.c +++ b/aviheader.c @@ -38,7 +38,7 @@ while(1){ if(id==mmioFOURCC('L','I','S','T')){ int len=stream_read_dword_le(demuxer->stream)-4; // list size id=stream_read_dword_le(demuxer->stream); // list type - if(verbose>=2) printf("LIST %.4s len=%d\n",&id,len); + if(verbose>=2) printf("LIST %.4s len=%d\n",(char *) &id,len); if(id==listtypeAVIMOVIE){ // found MOVI header demuxer->movi_start=stream_tell(demuxer->stream); @@ -50,7 +50,7 @@ while(1){ continue; } size2=stream_read_dword_le(demuxer->stream); - if(verbose>=2) printf("CHUNK %.4s len=%d\n",&id,size2); + if(verbose>=2) printf("CHUNK %.4s len=%d\n",(char *) &id,size2); chunksize=(size2+1)&(~1); switch(id){ case ckidAVIMAINHDR: // read 'avih' @@ -116,7 +116,7 @@ while(1){ } case ckidAVINEWINDEX: if(index_mode){ demuxer->idx_size=size2>>4; - if(verbose>=1) printf("Reading INDEX block, %d chunks for %d frames\n", + if(verbose>=1) printf("Reading INDEX block, %d chunks for %ld frames\n", demuxer->idx_size,avih.dwTotalFrames); demuxer->idx=malloc(demuxer->idx_size<<4); stream_read(demuxer->stream,(char*)demuxer->idx,demuxer->idx_size<<4); @@ -126,7 +126,7 @@ while(1){ } } if(chunksize>0) stream_skip(demuxer->stream,chunksize); else - if(chunksize<0) printf("WARNING!!! chunksize=%d (id=%.4s)\n",chunksize,&id); + if(chunksize<0) printf("WARNING!!! chunksize=%d (id=%.4s)\n",chunksize,(char *) &id); } @@ -170,7 +170,7 @@ if(index_mode>=2 || (demuxer->idx_size==0 && index_mode==1)){ if(c&0x40) idx->dwFlags=0; } - if(verbose>=2) printf("%08X %08X %.4s %02X %X\n",demuxer->filepos,id,&id,c,idx->dwFlags); + if(verbose>=2) printf("%08X %08X %.4s %02X %X\n",demuxer->filepos,id,(char *) &id,c,(unsigned int) idx->dwFlags); #if 0 { unsigned char tmp[64]; int i; diff --git a/demux_asf.c b/demux_asf.c index 29d8783f7f..059a3e8f65 100644 --- a/demux_asf.c +++ b/demux_asf.c @@ -190,7 +190,7 @@ int demux_asf_fill_buffer(demuxer_t *demux){ segs=p[0] & 0x3F; ++p; } - if(verbose>=4) printf("%08X: flag=%02X segs=%d pad=%d time=%d dur=%d\n", + if(verbose>=4) printf("%08X: flag=%02X segs=%d pad=%d time=%ld dur=%d\n", demux->filepos,flags,segs,padding,time,duration); for(seg=0;seg=2) printf("Unknown chunk: %.4s (%X)\n",&id,id); + if(verbose>=2) printf("Unknown chunk: %.4s (%X)\n",(char *) &id,id); } return NULL; } @@ -139,7 +139,7 @@ do{ continue; } if(!demux_avi_select_stream(demux,idx->ckid)){ - if(verbose>2) printf("Skip chunk %.4s (0x%X) \n",&idx->ckid,idx->ckid); + if(verbose>2) printf("Skip chunk %.4s (0x%X) \n",(char *)&idx->ckid,(unsigned int)idx->ckid); continue; // skip this chunk } @@ -156,14 +156,14 @@ do{ stream_seek(demux->stream,pos); id=stream_read_dword_le(demux->stream); if(id!=idx->ckid){ - printf("ChunkID mismatch! raw=%.4s idx=%.4s \n",&id,&idx->ckid); + printf("ChunkID mismatch! raw=%.4s idx=%.4s \n",(char *)&id,(char *)&idx->ckid); continue; } len=stream_read_dword_le(demux->stream); // if((len&(~1))!=(idx->dwChunkLength&(~1))){ // if((len)!=(idx->dwChunkLength)){ if((len!=idx->dwChunkLength)&&((len+1)!=idx->dwChunkLength)){ - printf("ChunkSize mismatch! raw=%d idx=%d \n",len,idx->dwChunkLength); + printf("ChunkSize mismatch! raw=%d idx=%ld \n",len,idx->dwChunkLength); continue; } } else { @@ -214,7 +214,7 @@ do{ continue; } if(ds && demux_avi_select_stream(demux,idx->ckid)!=ds){ - if(verbose>2) printf("Skip chunk %.4s (0x%X) \n",&idx->ckid,idx->ckid); + if(verbose>2) printf("Skip chunk %.4s (0x%X) \n",(char *)&idx->ckid,(unsigned int)idx->ckid); continue; // skip this chunk } @@ -235,14 +235,14 @@ do{ if(stream_eof(demux->stream)) return 0; if(id!=idx->ckid){ - printf("ChunkID mismatch! raw=%.4s idx=%.4s \n",&id,&idx->ckid); + printf("ChunkID mismatch! raw=%.4s idx=%.4s \n",(char *)&id,(char *)&idx->ckid); continue; } len=stream_read_dword_le(demux->stream); // if((len&(~1))!=(idx->dwChunkLength&(~1))){ // if((len)!=(idx->dwChunkLength)){ if((len!=idx->dwChunkLength)&&((len+1)!=idx->dwChunkLength)){ - printf("ChunkSize mismatch! raw=%d idx=%d \n",len,idx->dwChunkLength); + printf("ChunkSize mismatch! raw=%d idx=%ld \n",len,idx->dwChunkLength); continue; } } else return 0;