diff options
author | diego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2010-11-07 12:47:40 +0000 |
---|---|---|
committer | Uoti Urpala <uau@glyph.nonexistent.invalid> | 2010-11-08 18:05:12 +0200 |
commit | 12d3e0df9980822282f70dffad148b729dbee541 (patch) | |
tree | d298b2c8f5039eae7aeeb16dfd927bea0efcc134 /codec-cfg.c | |
parent | af4b23cd36cff0dc34cde59c6a154fd080d11216 (diff) | |
download | mpv-12d3e0df9980822282f70dffad148b729dbee541.tar.bz2 mpv-12d3e0df9980822282f70dffad148b729dbee541.tar.xz |
cleanup: don't check for NULL before free()
patch by Clément Bœsch, ubitux gmail com
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32598 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'codec-cfg.c')
-rw-r--r-- | codec-cfg.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/codec-cfg.c b/codec-cfg.c index ced013386a..84402ada7b 100644 --- a/codec-cfg.c +++ b/codec-cfg.c @@ -782,19 +782,13 @@ static void codecs_free(codecs_t* codecs,int count) { int i; for ( i = 0; i < count; i++) if ( codecs[i].name ) { - if( codecs[i].name ) - free(codecs[i].name); - if( codecs[i].info ) - free(codecs[i].info); - if( codecs[i].comment ) - free(codecs[i].comment); - if( codecs[i].dll ) - free(codecs[i].dll); - if( codecs[i].drv ) - free(codecs[i].drv); + free(codecs[i].name); + free(codecs[i].info); + free(codecs[i].comment); + free(codecs[i].dll); + free(codecs[i].drv); } - if (codecs) - free(codecs); + free(codecs); } void codecs_uninit_free(void) { |