[vlc-devel] commit: Don't check for impossible error involving object types ( Rémi Denis-Courmont )
git version control
git at videolan.org
Wed Jun 4 20:41:55 CEST 2008
vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Wed Jun 4 21:43:38 2008 +0300| [9649c59908053fd96488d1126a9149ce9ce40fc4]
Don't check for impossible error involving object types
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=9649c59908053fd96488d1126a9149ce9ce40fc4
---
modules/gui/beos/PreferencesWindow.cpp | 4 +---
modules/gui/macosx/prefs.m | 2 +-
modules/gui/qt4/input_manager.cpp | 2 +-
modules/gui/wince/preferences.cpp | 5 -----
4 files changed, 3 insertions(+), 10 deletions(-)
diff --git a/modules/gui/beos/PreferencesWindow.cpp b/modules/gui/beos/PreferencesWindow.cpp
index e033008..2370d91 100644
--- a/modules/gui/beos/PreferencesWindow.cpp
+++ b/modules/gui/beos/PreferencesWindow.cpp
@@ -445,11 +445,9 @@ ConfigItem::ConfigItem( intf_thread_t * _p_intf, char * name,
}
}
- if( !p_module || p_module->i_object_type != VLC_OBJECT_MODULE )
- {
+ if( !p_module )
/* Shouldn't happen */
return;
- }
module_config_t * p_item;
p_item = fSubModule ? ((module_t *)p_module->p_parent)->p_config :
diff --git a/modules/gui/macosx/prefs.m b/modules/gui/macosx/prefs.m
index 2e708b2..91c7b92 100644
--- a/modules/gui/macosx/prefs.m
+++ b/modules/gui/macosx/prefs.m
@@ -552,7 +552,7 @@ static VLCTreeItem *o_root_item = nil;
if( i_object_category == -1 )
{
p_parser = (module_t *) vlc_object_get( i_object_id );
- if( !p_parser || ((vlc_object_t*)p_parser)->i_object_type != VLC_OBJECT_MODULE )
+ if( !p_parser )
{
/* 0OOoo something went really bad */
return nil;
diff --git a/modules/gui/qt4/input_manager.cpp b/modules/gui/qt4/input_manager.cpp
index b62a10e..7804b9c 100644
--- a/modules/gui/qt4/input_manager.cpp
+++ b/modules/gui/qt4/input_manager.cpp
@@ -509,7 +509,7 @@ void MainInputManager::customEvent( QEvent *event )
}
/* Should be PLItemChanged Event */
- if( VLC_OBJECT_INTF == p_intf->i_object_type )
+ if( VLC_OBJECT_INTF == p_intf->i_object_type ) /* FIXME: don't use object type */
{
vlc_mutex_lock( &p_intf->change_lock );
if( p_input && ( p_input->b_dead || p_input->b_die ) )
diff --git a/modules/gui/wince/preferences.cpp b/modules/gui/wince/preferences.cpp
index 8738477..3905575 100644
--- a/modules/gui/wince/preferences.cpp
+++ b/modules/gui/wince/preferences.cpp
@@ -706,11 +706,6 @@ PrefsPanel::PrefsPanel( HWND parent, HINSTANCE hInst, intf_thread_t *_p_intf,
{
/* Get a pointer to the module */
p_module = (module_t *)vlc_object_get( i_object_id );
- if( p_module->i_object_type != VLC_OBJECT_MODULE )
- {
- /* 0OOoo something went really bad */
- return;
- }
/* Enumerate config options and add corresponding config boxes
* (submodules don't have config options, they are stored in the
More information about the vlc-devel
mailing list