]> git.mxchange.org Git - flightgear.git/blobdiff - src/Sound/fg_fx.cxx
Don't restore initial screen geometry because there is nothing in fg_os* to resize...
[flightgear.git] / src / Sound / fg_fx.cxx
index 7054e358e2bdd2c5d12f475394e691e70d01032a..b04d9a46fc14ef90018b77778144bbebe2b29686 100644 (file)
@@ -17,7 +17,7 @@
 //
 // You should have received a copy of the GNU General Public License
 // along with this program; if not, write to the Free Software
-// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 //
 // $Id$
 
@@ -85,7 +85,7 @@ FGFX::init()
    SGPropertyNode root;
    try {
       readProperties(path.str(), &root);
-   } catch (const sg_exception &e) {
+   } catch (const sg_exception &) {
       SG_LOG(SG_GENERAL, SG_ALERT,
        "Incorrect path specified in configuration file");
       return;
@@ -95,10 +95,15 @@ FGFX::init()
    for (i = 0; i < node->nChildren(); i++) {
       SGXmlSound *sound = new SGXmlSound();
 
-      sound->init(globals->get_props(), node->getChild(i),
-                  globals->get_soundmgr(), globals->get_fg_root());
+      try {
+         sound->init(globals->get_props(), node->getChild(i),
+                     globals->get_soundmgr(), globals->get_fg_root());
 
-      _sound.push_back(sound);
+         _sound.push_back(sound);
+      } catch ( sg_io_exception &e ) {
+         SG_LOG(SG_GENERAL, SG_ALERT, e.getFormattedMessage());
+         delete sound;
+      }
    }
 }