Index: trunk/BNC/src/PPP/pppMain.cpp
===================================================================
--- trunk/BNC/src/PPP/pppMain.cpp	(revision 5972)
+++ trunk/BNC/src/PPP/pppMain.cpp	(revision 5973)
@@ -52,4 +52,5 @@
 //////////////////////////////////////////////////////////////////////////////
 t_pppMain::t_pppMain() {
+  cout << "t_pppMain" << endl;
   _running = false;
 }
@@ -58,4 +59,5 @@
 //////////////////////////////////////////////////////////////////////////////
 t_pppMain::~t_pppMain() {
+  cout << "~t_pppMain" << endl;
   stop();
 }
@@ -89,4 +91,6 @@
 //////////////////////////////////////////////////////////////////////////////
 void t_pppMain::stop() {
+
+  cout << "t_pppMain::stop" << endl;
 
   if (!_running) {
Index: trunk/BNC/src/PPP/pppRun.cpp
===================================================================
--- trunk/BNC/src/PPP/pppRun.cpp	(revision 5972)
+++ trunk/BNC/src/PPP/pppRun.cpp	(revision 5973)
@@ -61,4 +61,6 @@
 ////////////////////////////////////////////////////////////////////////////
 t_pppRun::t_pppRun(const t_pppOptions* opt) {
+
+  cout << "t_pppRun" << endl;
 
   _opt = opt;
@@ -108,5 +110,8 @@
     connect(BNC_CORE, SIGNAL(mapSpeedSliderChanged(int)),    
             this, SLOT(slotSetSpeed(int)));
-  }
+    connect(BNC_CORE, SIGNAL(stopRinexPPP()), this, SLOT(slotSetStopFlag()));
+  }
+ 
+  _stopFlag = false;
 }
 
@@ -114,4 +119,5 @@
 ////////////////////////////////////////////////////////////////////////////
 t_pppRun::~t_pppRun() {
+  cout << "~t_pppRun" << endl;
 }
 
@@ -380,5 +386,5 @@
   int   nEpo = 0;
   const t_rnxObsFile::t_rnxEpo* epo = 0;
-  while ( (epo = _rnxObsFile->nextEpoch()) != 0 ) {
+  while ( !_stopFlag && (epo = _rnxObsFile->nextEpoch()) != 0 ) {
     ++nEpo;
 
@@ -439,2 +445,10 @@
   _speed = speed;
 }
+
+//  
+////////////////////////////////////////////////////////////////////////////
+void t_pppRun::slotSetStopFlag() {
+  QMutexLocker locker(&_mutex);
+  cout << "t_pppRun::slotSetStopFlag" << endl;
+  _stopFlag = true;
+}
Index: trunk/BNC/src/PPP/pppRun.h
===================================================================
--- trunk/BNC/src/PPP/pppRun.h	(revision 5972)
+++ trunk/BNC/src/PPP/pppRun.h	(revision 5973)
@@ -38,4 +38,5 @@
   void slotNewObs(QByteArray staID, QList<t_obs> obsList);
   void slotSetSpeed(int speed);
+  void slotSetStopFlag();
 
  private:
@@ -64,4 +65,5 @@
   t_corrFile*   _corrFile;
   int           _speed;
+  bool          _stopFlag;
 };
 
Index: trunk/BNC/src/PPP/pppThread.cpp
===================================================================
--- trunk/BNC/src/PPP/pppThread.cpp	(revision 5972)
+++ trunk/BNC/src/PPP/pppThread.cpp	(revision 5973)
@@ -57,4 +57,6 @@
 t_pppThread::t_pppThread(const t_pppOptions* opt) : QThread(0) {
 
+  cout << "t_pppThread" << endl;
+
   _opt       = opt;
   _pppRun    = 0;
@@ -69,4 +71,5 @@
 ////////////////////////////////////////////////////////////////////////////
 t_pppThread::~t_pppThread() {
+  cout << "~t_pppThread" << endl;
   delete _pppRun;
 }
