]> git.mxchange.org Git - flightgear.git/commitdiff
Csaba/Alexis : fix a NAN problem when wind is unspecified in a metar
authorfredb <fredb>
Tue, 30 Dec 2008 23:13:44 +0000 (23:13 +0000)
committerTim Moore <timoore@redhat.com>
Sat, 3 Jan 2009 23:24:05 +0000 (00:24 +0100)
src/Environment/fgmetar.cxx

index a543832e7d6bcb436b87dea9031984f02525b16b..b2b331fbf223469aec3b00e99fec829bb0906266 100644 (file)
@@ -99,6 +99,8 @@ FGMetar::FGMetar(const string& icao, const string& proxy, const string& port, co
                _wind_range_from = _wind_range_to = _wind_dir;
        }
 
+       if (_wind_speed == SGMetarNaN)
+               _wind_speed = 0.0;
        if (_gust_speed == SGMetarNaN)
                _gust_speed = 0.0;