X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FATCDCL%2FATC.cxx;h=2236619749b4096a3f8e66f639fed72d0dc29d9e;hb=33b7e3e32ec215931117e738b370107e0c47d036;hp=89cb5527302f99208a9ff03d7acecbe6674790ac;hpb=109d04b6057ad3e2d54489e6ffcf78374564017d;p=flightgear.git diff --git a/src/ATCDCL/ATC.cxx b/src/ATCDCL/ATC.cxx index 89cb55273..223661974 100644 --- a/src/ATCDCL/ATC.cxx +++ b/src/ATCDCL/ATC.cxx @@ -33,7 +33,7 @@ #include
#include
#include -#include +#include FGATC::FGATC() : freq(0), @@ -41,7 +41,6 @@ FGATC::FGATC() : range(0), _voice(true), _playing(false), - _vPtr(NULL), _sgr(NULL), _type(INVALID), _display(false) @@ -167,10 +166,9 @@ void FGATC::Render(std::string& msg, const float volume, _currentMsg = msg; size_t len; void* buf = NULL; - if (!_vPtr) - _vPtr = GetVoicePointer(); - if (_vPtr) - buf = _vPtr->WriteMessage((char*)msg.c_str(), &len); + FGATCVoice* vPtr = GetVoicePointer(); + if (vPtr) + buf = vPtr->WriteMessage((char*)msg.c_str(), &len); NoRender(refname); if(buf) { try {