From deef158822d9ad81a1c87a42da74963587a6a859 Mon Sep 17 00:00:00 2001 From: frohlich Date: Wed, 11 Mar 2009 05:34:02 +0000 Subject: [PATCH] Use a reference counted pointer for the condition. Modified Files: simgear/sound/xmlsound.hxx simgear/sound/xmlsound.cxx --- simgear/sound/xmlsound.cxx | 3 --- simgear/sound/xmlsound.hxx | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/simgear/sound/xmlsound.cxx b/simgear/sound/xmlsound.cxx index 18850f84..47438603 100644 --- a/simgear/sound/xmlsound.cxx +++ b/simgear/sound/xmlsound.cxx @@ -63,7 +63,6 @@ static const struct { SGXmlSound::SGXmlSound() : _sample(NULL), - _condition(NULL), _active(false), _name(""), _mode(SGXmlSound::ONCE), @@ -80,8 +79,6 @@ SGXmlSound::~SGXmlSound() if (_sample) _sample->stop(); - delete _condition; - _volume.clear(); _pitch.clear(); } diff --git a/simgear/sound/xmlsound.hxx b/simgear/sound/xmlsound.hxx index 66caa139..d161bbca 100644 --- a/simgear/sound/xmlsound.hxx +++ b/simgear/sound/xmlsound.hxx @@ -138,7 +138,7 @@ private: SGSoundMgr * _mgr; SGSharedPtr _sample; - SGCondition * _condition; + SGSharedPtr _condition; SGPropertyNode_ptr _property; bool _active; -- 2.39.5