mirror of https://github.com/mpv-player/mpv
ad_ffmpeg, vd_ffmpeg: remove pointless casts
Remove pointless casts of avcodec_find_decoder_by_name() return value. avcodec_find_decoder_by_name() already returns AVCodec*, so there is no need to cast the return value to this type. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32007 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
0e82595632
commit
740c927976
|
@ -105,7 +105,7 @@ static int init(sh_audio_t *sh_audio)
|
|||
avcodec_initialized=1;
|
||||
}
|
||||
|
||||
lavc_codec = (AVCodec *)avcodec_find_decoder_by_name(sh_audio->codec->dll);
|
||||
lavc_codec = avcodec_find_decoder_by_name(sh_audio->codec->dll);
|
||||
if(!lavc_codec){
|
||||
mp_tmsg(MSGT_DECAUDIO,MSGL_ERR,"Cannot find codec '%s' in libavcodec...\n",sh_audio->codec->dll);
|
||||
return 0;
|
||||
|
|
|
@ -177,7 +177,7 @@ static int init(sh_video_t *sh){
|
|||
|
||||
ctx->last_sample_aspect_ratio = (AVRational){0, 1};
|
||||
|
||||
lavc_codec = (AVCodec *)avcodec_find_decoder_by_name(sh->codec->dll);
|
||||
lavc_codec = avcodec_find_decoder_by_name(sh->codec->dll);
|
||||
if(!lavc_codec){
|
||||
mp_tmsg(MSGT_DECVIDEO, MSGL_ERR, "Cannot find codec '%s' in libavcodec...\n", sh->codec->dll);
|
||||
uninit(sh);
|
||||
|
|
Loading…
Reference in New Issue