SHARE
TWEET

Untitled

a guest Nov 22nd, 2010 118 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Index: maiaXmlRpcClient.cpp
  2. ===================================================================
  3. --- maiaXmlRpcClient.cpp        (revision 18)
  4. +++ maiaXmlRpcClient.cpp        (working copy)
  5. @@ -37,6 +37,13 @@
  6.  MaiaXmlRpcClient::MaiaXmlRpcClient(QUrl url, QObject* parent) : QObject(parent),
  7.         manager(this), request(url)
  8.  {
  9. +        if( url.userName().length() > 0 ) {
  10. +            //create autorization
  11. +            QString     s = url.userName() + QString(":") + url.password();
  12. +            QByteArray cs = "Basic " + s.toAscii().toBase64();
  13. +            request.setRawHeader("Authorization", cs);
  14. +            //qDebug() << QString("[LibMaia] autorize with [ %1 ]").arg( QString(cs));
  15. +        }
  16.         init();
  17.         setUrl(url);
  18.  }
RAW Paste Data
Top