mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-22 21:15:55 +03:00
Merge pull request #94 from owncloud/qt46fixurl
Fix url encoding in Qt46, Bug #93
This commit is contained in:
commit
b55d6742fe
1 changed files with 3 additions and 3 deletions
|
@ -130,7 +130,7 @@ void ownCloudInfo::mkdirRequest( const QString& dir )
|
||||||
if (url.scheme() == "https")
|
if (url.scheme() == "https")
|
||||||
conMode = QHttp::ConnectionModeHttps;
|
conMode = QHttp::ConnectionModeHttps;
|
||||||
|
|
||||||
QHttp* qhttp = new QHttp(url.host(), conMode, 0, this);
|
QHttp* qhttp = new QHttp(QString(url.encodedHost()), conMode, 0, this);
|
||||||
qhttp->setUser( CredentialStore::instance()->user(_connection),
|
qhttp->setUser( CredentialStore::instance()->user(_connection),
|
||||||
CredentialStore::instance()->password(_connection) );
|
CredentialStore::instance()->password(_connection) );
|
||||||
|
|
||||||
|
@ -139,8 +139,8 @@ void ownCloudInfo::mkdirRequest( const QString& dir )
|
||||||
connect(qhttp, SIGNAL(responseHeaderReceived(QHttpResponseHeader)), this, SLOT(qhttpResponseHeaderReceived(QHttpResponseHeader)));
|
connect(qhttp, SIGNAL(responseHeaderReceived(QHttpResponseHeader)), this, SLOT(qhttpResponseHeaderReceived(QHttpResponseHeader)));
|
||||||
//connect(qhttp, SIGNAL(authenticationRequired(QString,quint16,QAuthenticator*)), this, SLOT(qhttpAuthenticationRequired(QString,quint16,QAuthenticator*)));
|
//connect(qhttp, SIGNAL(authenticationRequired(QString,quint16,QAuthenticator*)), this, SLOT(qhttpAuthenticationRequired(QString,quint16,QAuthenticator*)));
|
||||||
|
|
||||||
QHttpRequestHeader header("MKCOL", url.path(), 1,1); /* header */
|
QHttpRequestHeader header("MKCOL", QString(url.encodedPath()), 1,1); /* header */
|
||||||
header.setValue("Host", url.host() );
|
header.setValue("Host", QString(url.encodedHost());
|
||||||
header.setValue("User-Agent", QString("mirall-%1").arg(MIRALL_STRINGIFY(MIRALL_VERSION)).toAscii() );
|
header.setValue("User-Agent", QString("mirall-%1").arg(MIRALL_STRINGIFY(MIRALL_VERSION)).toAscii() );
|
||||||
header.setValue("Accept-Charset", "ISO-8859-1,utf-8;q=0.7,*;q=0.7");
|
header.setValue("Accept-Charset", "ISO-8859-1,utf-8;q=0.7,*;q=0.7");
|
||||||
header.setValue("Accept-Language", "it,de-de;q=0.8,it-it;q=0.6,en-us;q=0.4,en;q=0.2");
|
header.setValue("Accept-Language", "it,de-de;q=0.8,it-it;q=0.6,en-us;q=0.4,en;q=0.2");
|
||||||
|
|
Loading…
Reference in a new issue