vlc | branch: master | Mirsal Ennaime <[email protected]> | Wed Feb  6 
15:16:26 2013 +0100| [56180db3def98fd0c9e4b9c32e6941074e1db8c4] | committer: 
Mirsal Ennaime

dbus: Add memory allocation failure check

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

 modules/control/dbus/dbus_root.c |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/modules/control/dbus/dbus_root.c b/modules/control/dbus/dbus_root.c
index caa0cf3..358bc8a 100644
--- a/modules/control/dbus/dbus_root.c
+++ b/modules/control/dbus/dbus_root.c
@@ -481,6 +481,12 @@ PropertiesChangedSignal( intf_thread_t    *p_intf,
     i_properties = vlc_dictionary_keys_count( p_changed_properties );
     ppsz_properties = vlc_dictionary_all_keys( p_changed_properties );
 
+    if( unlikely(!ppsz_properties) )
+    {
+        dbus_message_iter_abandon_container( &args, &invalidated_properties );
+        return DBUS_HANDLER_RESULT_NEED_MEMORY;
+    }
+
     for( int i = 0; i < i_properties; i++ )
     {
         PROPERTY_MAPPING_BEGIN

_______________________________________________
vlc-commits mailing list
[email protected]
http://mailman.videolan.org/listinfo/vlc-commits

Reply via email to