Changeset 1528 in ntrip
- Timestamp:
- Jan 21, 2009, 1:14:16 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/bncnetqueryrtp.cpp
r1522 r1528 86 86 // Default scheme 87 87 // -------------- 88 QUrl urlLoc(url);89 urlLoc.setScheme("rtsp");88 _url = url; 89 _url.setScheme("rtsp"); 90 90 91 91 // Connect the Socket … … 96 96 97 97 if ( proxyHost.isEmpty() ) { 98 _socket->connectToHost( urlLoc.host(), urlLoc.port());98 _socket->connectToHost(_url.host(), _url.port()); 99 99 } 100 100 else { … … 105 105 // -------------- 106 106 if (_socket->waitForConnected(timeOut)) { 107 QString uName = QUrl::fromPercentEncoding( urlLoc.userName().toAscii());108 QString passW = QUrl::fromPercentEncoding( urlLoc.password().toAscii());107 QString uName = QUrl::fromPercentEncoding(_url.userName().toAscii()); 108 QString passW = QUrl::fromPercentEncoding(_url.password().toAscii()); 109 109 QByteArray userAndPwd; 110 110 … … 123 123 124 124 QByteArray reqStr; 125 reqStr = "SETUP " + urlLoc.toEncoded() + " RTSP/1.0\r\n"125 reqStr = "SETUP " + _url.toEncoded() + " RTSP/1.0\r\n" 126 126 + "CSeq: 1\r\n" 127 127 + "Ntrip-Version: Ntrip/2.0\r\n" … … 178 178 } 179 179 180 reqStr = "PLAY " + urlLoc.toEncoded() + " RTSP/1.0\r\n"180 reqStr = "PLAY " + _url.toEncoded() + " RTSP/1.0\r\n" 181 181 + "CSeq: 2\r\n" 182 182 + "Session: " + session + "\r\n" … … 192 192 while (!line.isEmpty()) { 193 193 if (line.indexOf("200 OK") != -1) { 194 emit newMessage( urlLoc.host().toAscii() +195 urlLoc.path().toAscii() +194 emit newMessage(_url.host().toAscii() + 195 _url.path().toAscii() + 196 196 ": UDP connection established", true); 197 197 return;
Note:
See TracChangeset
for help on using the changeset viewer.