[vlc-devel] [PATCH] control: check calloc return value correctly
    Matthew Whitworth 
    mwhitworth at gmail.com
       
    Fri Mar  2 16:34:12 CET 2018
    
    
  
(resend for correct email title)
Incorrect check after calloc returns.
---
diff --git a/src/input/control.c b/src/input/control.c
index 75a2f64355..2b2f7108f1 100644
--- a/src/input/control.c
+++ b/src/input/control.c
@@ -392,7 +392,7 @@ int input_vaControl( input_thread_t *p_input, int
i_query, va_list args )
             }
             *array = calloc( p_title->i_seekpoint, sizeof(**array) );
-            if( unlikely(array == NULL) )
+            if( unlikely(*array == NULL) )
             {
                 vlc_mutex_unlock( &priv->p_item->lock );
                 return VLC_ENOMEM;
    
    
More information about the vlc-devel
mailing list