Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/src/browser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ BrowserPrivate::BrowserPrivate(Browser *browser, AbstractServer *server, const Q
bool BrowserPrivate::updateService(const QByteArray &fqName)
{
// Split the FQDN into service name and type
int index = fqName.indexOf('.');
int index = fqName.indexOf('_') - 1;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps this should be "._" (assume empty service names shouldn't be supported)?

QByteArray serviceName = fqName.left(index);
QByteArray serviceType = fqName.mid(index + 1);

Expand Down
2 changes: 1 addition & 1 deletion tests/TestBrowser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

Q_DECLARE_METATYPE(QMdnsEngine::Service)

const QByteArray Name = "Test";
const QByteArray Name = "Test.DotTest";
const QByteArray Type = "_test._tcp.local.";
const QByteArray Fqdn = Name + "." + Type;
const QByteArray Target = "Test.local.";
Expand Down