[Pkg-osm-commits] [SCM] monav branch, master, updated. debian/0.3-4-1-gb30c243

David Paleino dapal at debian.org
Tue Aug 23 18:11:56 UTC 2011


The following commit has been merged in the master branch:
commit b30c2431350af9090e33e2b8d1c83399ecd9527e
Author: David Paleino <dapal at debian.org>
Date:   Tue Aug 23 20:09:02 2011 +0200

    Backport fix to avoid freezing when GPSd is not available, thanks to Timo Juhani Lindfors (Closes: #632650)

diff --git a/debian/changelog b/debian/changelog
index aee487d..88c79d3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+monav (0.3-5) UNRELEASED; urgency=low
+
+  * Backport fix to avoid freezing when GPSd is not available, thanks
+    to Timo Juhani Lindfors (Closes: #632650)
+
+ -- David Paleino <dapal at debian.org>  Tue, 23 Aug 2011 20:08:03 +0200
+
 monav (0.3-4) unstable; urgency=low
 
   * Drop -march=native from the compilation (Closes: #626671)
diff --git a/debian/patches/06-implement_gpsd_interface.patch b/debian/patches/06-implement_gpsd_interface.patch
index b39dde2..0e4c34a 100644
--- a/debian/patches/06-implement_gpsd_interface.patch
+++ b/debian/patches/06-implement_gpsd_interface.patch
@@ -1,16 +1,17 @@
 From: bedlore at gmail.com
 Subject: implement GPSd interface in MoNav
 Origin: upstream, http://code.google.com/p/monav/issues/detail?id=39
+ and fixes from http://code.google.com/p/monav/source/detail?r=3ec821f2cdf0
 Forwarded: not-needed
 
 ---
  client/client.pro                 |    4 
- client/gpsdpositioninfosource.cpp |  176 +++++++++++++++
- client/gpsdpositioninfosource.h   |   46 ++++
+ client/gpsdpositioninfosource.cpp |  188 ++++++++++++++++
+ client/gpsdpositioninfosource.h   |   47 ++++
  client/json.cpp                   |  433 ++++++++++++++++++++++++++++++++++++++
  client/json.h                     |  161 ++++++++++++++
  client/routinglogic.cpp           |    4 
- 6 files changed, 824 insertions(+)
+ 6 files changed, 837 insertions(+)
 
 --- monav.orig/client/client.pro
 +++ monav/client/client.pro
@@ -47,14 +48,14 @@ Forwarded: not-needed
  #ifndef NOQTMOBILE
  	d->gpsSource = QGeoPositionInfoSource::createDefaultSource( this );
 +	if ( d->gpsSource == NULL )
-+		d->gpsSource = new GpsdPositionInfoSource( this );
++		d->gpsSource = GpsdPositionInfoSource::create( this );
 +
  	if ( d->gpsSource == NULL ) {
  		qDebug() << "No GPS Sensor found! GPS Updates are not available";
  	} else {
 --- /dev/null
 +++ monav/client/gpsdpositioninfosource.cpp
-@@ -0,0 +1,176 @@
+@@ -0,0 +1,188 @@
 +/****************************************************************************
 +** GpsdPositionInfoSource
 +** (c) 2011 by Till Harbaum <till at harbaum.org>
@@ -231,9 +232,21 @@ Forwarded: not-needed
 +int GpsdPositionInfoSource::minimumUpdateInterval() const {
 +  return 1000;
 +}
++
++GpsdPositionInfoSource * GpsdPositionInfoSource::create(QObject *parent)
++{
++        GpsdPositionInfoSource* source = new GpsdPositionInfoSource( parent );
++        if ( !source->m_tcpSocket->waitForConnected( 100 ) )
++        {
++                if ( !source->m_tcpSocket->waitForConnected( 100 ) )
++                source->deleteLater();
++                return NULL;
++        }
++        return source;
++}
 --- /dev/null
 +++ monav/client/gpsdpositioninfosource.h
-@@ -0,0 +1,46 @@
+@@ -0,0 +1,47 @@
 +/****************************************************************************
 +** GpsdPositionInfoSource
 +** (c) 2011 by Till Harbaum <till at harbaum.org>
@@ -253,7 +266,7 @@ Forwarded: not-needed
 +    Q_OBJECT
 +
 + public:
-+  GpsdPositionInfoSource(QObject *parent = 0);
++  static GpsdPositionInfoSource* create(QObject *parent = NULL);
 +  ~GpsdPositionInfoSource();
 +
 +  void setUpdateInterval(int msec);
@@ -272,6 +285,7 @@ Forwarded: not-needed
 +  void displayError(QAbstractSocket::SocketError);
 +
 + private:
++  GpsdPositionInfoSource(QObject *parent = 0);
 +  qreal getReal(const QMap<QString, QVariant> &, const QString &);
 +  void setAttribute(QGeoPositionInfo &, QGeoPositionInfo::Attribute, const QMap<QString, QVariant> &, const QString &);
 +  void parse(const QString &);

-- 
fast navigation system featuring exact routing



More information about the Pkg-osm-commits mailing list