[vlc-commits] macos: remove tautology check

Rémi Denis-Courmont git at videolan.org
Sat Mar 16 11:07:54 CET 2019


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Fri Mar 15 04:21:41 2019 +0200| [13818435c537ad62f79229a0b5e01fe95d5ee7bb] | committer: Rémi Denis-Courmont

macos: remove tautology check

object cannot be nul here, since it was held.

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

 modules/gui/macosx/menus/VLCMainMenu.m | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/modules/gui/macosx/menus/VLCMainMenu.m b/modules/gui/macosx/menus/VLCMainMenu.m
index 41359c320f..f4f2491ca4 100644
--- a/modules/gui/macosx/menus/VLCMainMenu.m
+++ b/modules/gui/macosx/menus/VLCMainMenu.m
@@ -1579,13 +1579,9 @@
         VLCAutoGeneratedMenuContent *menuContent = (VLCAutoGeneratedMenuContent *)data;
 
         p_object = [menuContent vlcObject];
-
-        if (p_object != NULL) {
-            var_Set(p_object, [menuContent name], [menuContent value]);
-            vlc_object_release(p_object);
-            return true;
-        }
-        return VLC_EGENERIC;
+        var_Set(p_object, [menuContent name], [menuContent value]);
+        vlc_object_release(p_object);
+        return true;
     }
 }
 



More information about the vlc-commits mailing list