Fix bug on Windows, time() is UTC there also.
This renders sgGMTime obsolete, it will go away shortly. Thanks to Ron H for help tracking this down and Richard Harrison for his knowledge of Windows APIs in confirming the issue.
This commit is contained in:
parent
29fe9316af
commit
b13dd05aca
1 changed files with 1 additions and 1 deletions
|
@ -160,7 +160,7 @@ FGMetar::FGMetar(const string& icao) :
|
||||||
|
|
||||||
long FGMetar::getAge_min() const
|
long FGMetar::getAge_min() const
|
||||||
{
|
{
|
||||||
time_t now = _x_proxy ? _rq_time : sgGMTime();
|
time_t now = _x_proxy ? _rq_time : time(nullptr);
|
||||||
return (now - _time) / 60;
|
return (now - _time) / 60;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue