From: david Date: Wed, 27 Mar 2002 12:59:53 +0000 (+0000) Subject: Fixed a bug report from Frederic Bouvier: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=ec6a0b2810277970878771f0685ad274d2c59588;p=flightgear.git Fixed a bug report from Frederic Bouvier: as a follow-up of my previous message, I found that in panel.cxx, function const char *FGTextLayer::Chunk::getValue () const, there is the use of a member variable _buf that seems to be uninitialized. --- diff --git a/src/Cockpit/panel.cxx b/src/Cockpit/panel.cxx index 25c2c44e4..18887b83b 100644 --- a/src/Cockpit/panel.cxx +++ b/src/Cockpit/panel.cxx @@ -1096,6 +1096,7 @@ const char * FGTextLayer::Chunk::getValue () const { if (test()) { + _buf[0] = '\0'; switch (_type) { case TEXT: sprintf(_buf, _fmt.c_str(), _text.c_str());