Changeset 9838 in ntrip for trunk/BNC/src/upload
- Timestamp:
- Sep 27, 2022, 2:22:56 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/upload/bncrtnetuploadcaster.cpp
r9823 r9838 264 264 QMutexLocker locker(&_mutex); 265 265 266 267 268 269 /* Append to internal buffer 266 // Append to internal buffer 270 267 // ------------------------- 271 268 _rtnetStreamBuffer.append(QByteArray(buffer, bufLen)); … … 309 306 emit(newMessage( 310 307 "bncRtnetUploadCaster: less than 2 lines to decode " + _casterID.toLatin1(), false)); 311 return;312 }313 */314 315 316 // Append to internal buffer317 // -------------------------318 _rtnetStreamBuffer.append(QByteArray(buffer, bufLen));319 320 // Select buffer part that contains last epoch321 // -------------------------------------------322 QStringList lines;323 int iEpoBeg = _rtnetStreamBuffer.lastIndexOf('*'); // begin of last epoch324 if (iEpoBeg == -1) {325 _rtnetStreamBuffer.clear();326 return;327 }328 _rtnetStreamBuffer = _rtnetStreamBuffer.mid(iEpoBeg);329 330 int iEpoEnd = _rtnetStreamBuffer.lastIndexOf("EOE"); // end of last epoch331 if (iEpoEnd == -1) {332 return;333 }334 else {335 lines = _rtnetStreamBuffer.left(iEpoEnd).split('\n', QString::SkipEmptyParts);336 _rtnetStreamBuffer = _rtnetStreamBuffer.mid(iEpoEnd+3);337 }338 339 if (lines.size() < 2) {340 emit(newMessage(341 "bncRtnetUploadCaster: less than 2 lines to decode " + _casterID.toLatin1(), false));342 308 return; 343 309 }
Note:
See TracChangeset
for help on using the changeset viewer.