Fix crash in tests; not sure about the root cause.
authorCarl Hetherington <carl@carlh.net>
Sat, 9 Jun 2012 22:36:59 +0000 (22:36 +0000)
committerCarl Hetherington <carl@carlh.net>
Sat, 9 Jun 2012 22:36:59 +0000 (22:36 +0000)
git-svn-id: svn://localhost/ardour2/branches/3.0@12639 d708f5d6-7413-0410-9779-e7cbd77b26cf

libs/surfaces/mackie/surface.cc

index f11431a06934e40a46f8528c769e6e38b590bbb3..e55dad18e35e8ed62cc346e0b0ab52475cfccf09 100644 (file)
@@ -239,6 +239,9 @@ Surface::master_gain_changed ()
        }
 
        boost::shared_ptr<AutomationControl> ac = _master_fader->control();
+       if (!ac) {
+               return;
+       }
 
        float normalized_position = ac->internal_to_interface (ac->get_value());
        if (normalized_position == _last_master_gain_written) {