Changeset 457 in ntrip for trunk/BNC/RTIGS/RTIGSDecoder.cpp
- Timestamp:
- May 10, 2007, 4:35:43 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/RTIGS/RTIGSDecoder.cpp
r367 r457 64 64 // Append the incomming data to the internal buffer 65 65 // ------------------------------------------------ 66 _buffer.append( QByteArray(buffer, bufLen));66 _buffer.append(buffer, bufLen); 67 67 68 68 // Find the beginning of the message 69 69 // --------------------------------- 70 70 bool found = false; 71 for ( intii = 0; ii < _buffer.size(); ii++) {71 for (unsigned ii = 0; ii < _buffer.size(); ii++) { 72 72 unsigned short xx; 73 memcpy( (void*) &xx, &_buffer .data()[ii], sizeof(xx) );73 memcpy( (void*) &xx, &_buffer[ii], sizeof(xx) ); 74 74 if (_GPSTrans.f_IsLittleEndian) { 75 75 SwitchBytes( (char*) &xx, sizeof(xx) ); 76 76 } 77 77 if (xx == 200) { 78 _buffer = _buffer. mid(ii);78 _buffer = _buffer.substr(ii); 79 79 found = true; 80 80 break; … … 126 126 // Unprocessed bytes remain in buffer 127 127 // ---------------------------------- 128 _buffer = _buffer. mid(numbytes);128 _buffer = _buffer.substr(numbytes); 129 129 }
Note:
See TracChangeset
for help on using the changeset viewer.