From 5896036cb381bef1730b0140e90160618a557a74 Mon Sep 17 00:00:00 2001 From: reimar Date: Sun, 12 Sep 2010 16:10:18 +0000 Subject: [PATCH] demux_nemesi: Remove a pointless if git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32208 b3059339-0415-0410-9bf9-f77b7e298cf2 Reindent. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32209 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libmpdemux/demux_nemesi.c | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) diff --git a/libmpdemux/demux_nemesi.c b/libmpdemux/demux_nemesi.c index 2b2f6d2438..b5c9cd4ad2 100644 --- a/libmpdemux/demux_nemesi.c +++ b/libmpdemux/demux_nemesi.c @@ -232,13 +232,9 @@ static demuxer_t* demux_open_rtp(demuxer_t* demuxer) link_session_and_fetch_conf(ndsd, NEMESI_SESSION_AUDIO, sess, &buff, NULL); - if (buff.len) { - wf = calloc(1,sizeof(*wf)+buff.len); - wf->cbSize = buff.len; - memcpy(wf+1, buff.data, buff.len); - } else { - wf = calloc(1,sizeof(*wf)); - } + wf = calloc(1,sizeof(*wf)+buff.len); + wf->cbSize = buff.len; + memcpy(wf+1, buff.data, buff.len); sh_audio->wf = wf; d_audio->sh = sh_audio; @@ -268,14 +264,9 @@ static demuxer_t* demux_open_rtp(demuxer_t* demuxer) link_session_and_fetch_conf(ndsd, NEMESI_SESSION_VIDEO, sess, &buff, &fps); - if (buff.len) { - bih = calloc(1,sizeof(*bih)+buff.len); - bih->biSize = sizeof(*bih)+buff.len; - memcpy(bih+1, buff.data, buff.len); - } else { - bih = calloc(1,sizeof(*bih)); - bih->biSize = sizeof(*bih); - } + bih = calloc(1,sizeof(*bih)+buff.len); + bih->biSize = sizeof(*bih)+buff.len; + memcpy(bih+1, buff.data, buff.len); sh_video = new_sh_video(demuxer,0); sh_video->bih = bih;