diff options
Diffstat (limited to 'geography/merkaartor/patches')
-rw-r--r-- | geography/merkaartor/patches/patch-aa | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/geography/merkaartor/patches/patch-aa b/geography/merkaartor/patches/patch-aa new file mode 100644 index 00000000000..38fb84a4c76 --- /dev/null +++ b/geography/merkaartor/patches/patch-aa @@ -0,0 +1,52 @@ +$NetBSD: patch-aa,v 1.3 2011/04/11 20:15:00 drochner Exp $ + +--- src/GPS/qgpsdevice.cpp.orig 2011-02-10 12:00:35.000000000 +0000 ++++ src/GPS/qgpsdevice.cpp +@@ -959,10 +959,9 @@ void QGPSDDevice::run() + // exec(); + QEventLoop l; + +- Server = new gpsmm(); + errno = 0; +- gpsdata = Server->open(M_PREFS->getGpsdHost().toAscii().data(),QString::number(M_PREFS->getGpsdPort()).toAscii().data()); +- if (!gpsdata) { ++ Server = new gpsmm(M_PREFS->getGpsdHost().toAscii().data(),QString::number(M_PREFS->getGpsdPort()).toAscii().data()); ++ if (!Server) { + #ifndef Q_OS_WIN32 + QString msg( (errno<0) ? gps_errstr(errno) : strerror(errno) ); + #else +@@ -978,7 +977,7 @@ void QGPSDDevice::run() + + forever { + #if GPSD_API_MAJOR_VERSION > 3 +- if (Server->waiting()) ++ if (Server->waiting(0)) + #endif + onDataAvailable(); + l.processEvents(); +@@ -994,7 +993,7 @@ void QGPSDDevice::onDataAvailable() + if (!gpsdata) + return; + #else +- if ( Server->waiting() ) ++ if ( Server->waiting(0) ) + { + errno = 0; + gpsdata = Server->read(); +@@ -1027,13 +1026,13 @@ void QGPSDDevice::onDataAvailable() + setLatitude(gpsdata->fix.latitude); + setLongitude(gpsdata->fix.longitude); + double Alt = gpsdata->fix.altitude; +- if (!__isnan(Alt)) ++ if (!std::isnan(Alt)) + setAltitude(Alt); + double Speed = gpsdata->fix.speed; +- if (!__isnan(Speed)) ++ if (!std::isnan(Speed)) + setSpeed(Speed); + double Heading = gpsdata->fix.track; +- if (!__isnan(Heading)) ++ if (!std::isnan(Heading)) + setHeading(Heading); + if (gpsdata->fix.time) + cur_datetime = QDateTime::fromTime_t(gpsdata->fix.time); |