Changeset 836 in ntrip for trunk/BNS/bns.cpp


Ignore:
Timestamp:
Apr 16, 2008, 12:09:18 PM (16 years ago)
Author:
mervart
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNS/bns.cpp

    r835 r836  
    2929  this->setTerminationEnabled(true);
    3030 
     31  connect(this, SIGNAL(moveSocket(QThread*)),
     32          this, SLOT(slotMoveSocket(QThread*)));
     33
    3134  // Thread that handles broadcast ephemeris
    3235  // ---------------------------------------
     
    220223  // ------------
    221224  while (true) {
     225
     226    if (_clkSocket && _clkSocket->thread() != currentThread()) {
     227      emit(moveSocket(currentThread()));
     228    }
     229
    222230    if (_clkSocket && _clkSocket->state() == QAbstractSocket::ConnectedState) {
    223231      if ( _clkSocket->canReadLine()) {
     
    311319  }
    312320}
     321
     322//
     323////////////////////////////////////////////////////////////////////////////
     324void t_bns::slotMoveSocket(QThread* tt) {
     325  _clkSocket->setParent(0);
     326  _clkSocket->moveToThread(tt);
     327  slotMessage("bns::slotMoveSocket");
     328}
Note: See TracChangeset for help on using the changeset viewer.