From bda741fbcd7fc59f7e86a4f741c6a90cfaf10a54 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Tue, 28 Feb 2012 13:40:37 +0000 Subject: [PATCH] We already checked for vstfx being NULL, so the second check can reasonably be an assert. git-svn-id: svn://localhost/ardour2/branches/3.0@11540 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/linux_vst_info_file.cc | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/libs/ardour/linux_vst_info_file.cc b/libs/ardour/linux_vst_info_file.cc index b224220eea..8eff37e77a 100644 --- a/libs/ardour/linux_vst_info_file.cc +++ b/libs/ardour/linux_vst_info_file.cc @@ -5,6 +5,7 @@ /***********************************************************/ #include +#include #include #include @@ -279,6 +280,8 @@ int vstfx_can_midi (VSTState* vstfx) static VSTInfo * vstfx_info_from_plugin (VSTState* vstfx) { + assert (vstfx); + VSTInfo* info = (VSTInfo*) malloc (sizeof (VSTInfo)); AEffect *plugin; @@ -290,12 +293,6 @@ vstfx_info_from_plugin (VSTState* vstfx) char creator[65] = "Unknown\0"; - if(!vstfx) - { - vstfx_error( "** ERROR ** VSTFXinfofile : vstfx ptr is 0\n" ); - return 0; - } - if(!info) return 0;