[vlc-commits] commit: Fixed a check on malloc failure in libvlc_media_get_tracks_info(). (Laurent Aimar )

git at videolan.org git at videolan.org
Sun Oct 31 13:05:28 CET 2010


vlc | branch: master | Laurent Aimar <fenrir at videolan.org> | Sun Oct 31 12:35:44 2010 +0100| [ca1bdb8650fa6875cea42e76ff1d88e457e471ab] | committer: Laurent Aimar 

Fixed a check on malloc failure in libvlc_media_get_tracks_info().

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ca1bdb8650fa6875cea42e76ff1d88e457e471ab
---

 src/control/media.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/control/media.c b/src/control/media.c
index 3f39841..46c6740 100644
--- a/src/control/media.c
+++ b/src/control/media.c
@@ -691,7 +691,7 @@ libvlc_media_get_tracks_info( libvlc_media_t *p_md, libvlc_media_track_info_t **
     const int i_es = p_input_item->i_es;
     *pp_es = (i_es > 0) ? malloc( i_es * sizeof(libvlc_media_track_info_t) ) : NULL;
 
-    if( !pp_es ) /* no ES, or OOM */
+    if( !*pp_es ) /* no ES, or OOM */
     {
         vlc_mutex_unlock( &p_input_item->lock );
         return 0;



More information about the vlc-commits mailing list