Changeset 392 in ntrip
- Timestamp:
- Feb 2, 2007, 10:45:47 AM (18 years ago)
- Location:
- trunk/BNC
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/bnccaster.cpp
r387 r392 92 92 if (_waitTime < 1) { 93 93 _waitTime = 1; 94 } 95 96 if ( settings.value("rnxPath").toString().isEmpty() ) { 97 _rinexWriters = 0; 98 } 99 else { 100 _rinexWriters = new QMap<QString, bncRinex*>; 94 101 } 95 102 … … 115 122 delete _sockets; 116 123 delete _epochs; 124 delete _rinexWriters; 117 125 } 118 126 … … 122 130 QMutexLocker locker(&_mutex); 123 131 124 if (_rinexWriters .find(staID) != _rinexWriters.end()) {125 bncRinex* rnx = _rinexWriters .find(staID).value();132 if (_rinexWriters && _rinexWriters->find(staID) != _rinexWriters->end()) { 133 bncRinex* rnx = _rinexWriters->find(staID).value(); 126 134 rnx->setReconnectFlag(true); 127 135 } … … 149 157 // Prepare RINEX Output 150 158 // -------------------- 151 if (_rinexWriters.find(obs->StatID) == _rinexWriters.end()) { 152 _rinexWriters.insert(obs->StatID, new bncRinex(obs->StatID, 153 mountPoint, format, latitude, longitude, nmea)); 154 } 155 bncRinex* rnx = _rinexWriters.find(obs->StatID).value(); 156 if (_samplingRate == 0 || iSec % _samplingRate == 0) { 157 rnx->deepCopy(obs); 158 } 159 rnx->dumpEpoch(_newTime); 159 if (_rinexWriters) { 160 if (_rinexWriters->find(obs->StatID) == _rinexWriters->end()) { 161 _rinexWriters->insert(obs->StatID, new bncRinex(obs->StatID, mountPoint, 162 format, latitude, longitude, nmea)); 163 } 164 bncRinex* rnx = _rinexWriters->find(obs->StatID).value(); 165 if (_samplingRate == 0 || iSec % _samplingRate == 0) { 166 rnx->deepCopy(obs); 167 } 168 rnx->dumpEpoch(_newTime); 169 } 160 170 161 171 // First time, set the _lastDumpSec immediately -
trunk/BNC/bnccaster.h
r382 r392 70 70 QList<QTcpSocket*>* _sockets; 71 71 QList<QByteArray> _staIDs; 72 QMap<QString, bncRinex*> 72 QMap<QString, bncRinex*>* _rinexWriters; 73 73 QList<bncGetThread*> _threads; 74 74 int _samplingRate;
Note:
See TracChangeset
for help on using the changeset viewer.