Changeset 1366 in ntrip
- Timestamp:
- Dec 27, 2008, 11:03:14 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/BNC/bncsocket.cpp ¶
r1364 r1366 39 39 //////////////////////////////////////////////////////////////////////////// 40 40 bncSocket::~bncSocket() { 41 cout << "~bncSocket" << endl;42 41 delete _socket; 43 42 delete _http; … … 81 80 bool bncSocket::canReadLine() const { 82 81 if (_http) { 83 cout << "canReadLine " << _buffer.size() << endl;84 82 if (_buffer.indexOf('\n') != -1) { 85 83 return true; … … 102 100 if (_http) { 103 101 int ind = _buffer.indexOf('\n'); 104 cout << "readLine " << ind << endl;105 102 if (ind != -1) { 106 103 QByteArray ret = _buffer.left(ind+1); 107 cout << ret.data();108 104 _buffer = _buffer.right(_buffer.size()-ind-1); 109 105 return ret; … … 156 152 157 153 if (ntripVersion == "AUTO") { 158 emit newMessage("NTRIP Version AUTO not yet implemented", "true");154 emit newMessage("NTRIP Version AUTO not yet implemented", true); 159 155 return failure; 160 156 } … … 163 159 } 164 160 else if (ntripVersion != "1") { 165 emit newMessage("Unknown NTRIP Version " + ntripVersion, "true");161 emit newMessage("Unknown NTRIP Version " + ntripVersion, true); 166 162 return failure; 167 163 } … … 280 276 // 281 277 //////////////////////////////////////////////////////////////////////////// 282 void bncSocket::slotRequestFinished(int id, bool error) { 283 cout << "slotRequestFinished " << id << endl; 278 void bncSocket::slotRequestFinished(int /* id */, bool error) { 284 279 if (error) { 285 cout << "error: " << _http->error() << " "286 <<_http->errorString().toAscii().data() << endl;280 emit newMessage("slotRequestFinished " + 281 _http->errorString().toAscii(), true); 287 282 } 288 283 } … … 291 286 //////////////////////////////////////////////////////////////////////////// 292 287 void bncSocket::slotReadyRead(const QHttpResponseHeader&) { 293 cout << "slotReadyRead " << _buffer.size() << " "294 << _http->bytesAvailable() << endl;295 288 _buffer.append(_http->readAll()); 296 cout << _buffer.data();297 289 emit quitEventLoop(); 298 290 } … … 301 293 //////////////////////////////////////////////////////////////////////////// 302 294 void bncSocket::slotDone(bool error) { 303 cout << "slotDone " << endl;304 295 if (error) { 305 cout << "error: " <<_http->error() << " "306 << _http->errorString().toAscii().data() << endl;307 }296 emit newMessage("slotDone " + _http->errorString().toAscii(), true); 297 } 298 emit quitEventLoop(); 308 299 } 309 300 … … 345 336 _http->request(request); 346 337 347 cout << "before return" << endl;348 338 return success; 349 339 }
Note:
See TracChangeset
for help on using the changeset viewer.