mirror of
https://github.com/JulianGro/overte.git
synced 2025-05-09 09:39:41 +02:00
handle urls in the form of <domain>:<port>/path
This commit is contained in:
parent
9af7b904ab
commit
fb8a0e3aee
1 changed files with 1 additions and 1 deletions
|
@ -250,7 +250,7 @@ bool AddressManager::handleUrl(const QUrl& lookupUrlIn, LookupTrigger trigger) {
|
||||||
lookupUrl.setScheme(URL_SCHEME_HIFI);
|
lookupUrl.setScheme(URL_SCHEME_HIFI);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const QRegExp PORT_REGEX = QRegExp("\\d{1,5}");
|
static const QRegExp PORT_REGEX = QRegExp("\\d{1,5}(\\/.*)?");
|
||||||
if(!lookupUrl.scheme().isEmpty() && lookupUrl.host().isEmpty() && PORT_REGEX.exactMatch(lookupUrl.path())) {
|
if(!lookupUrl.scheme().isEmpty() && lookupUrl.host().isEmpty() && PORT_REGEX.exactMatch(lookupUrl.path())) {
|
||||||
// this is in the form somewhere:<port>, convert it to hifi://somewhere:<port>
|
// this is in the form somewhere:<port>, convert it to hifi://somewhere:<port>
|
||||||
lookupUrl = QUrl(URL_SCHEME_HIFI + "://" + lookupUrl.toString());
|
lookupUrl = QUrl(URL_SCHEME_HIFI + "://" + lookupUrl.toString());
|
||||||
|
|
Loading…
Reference in a new issue