Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chip-device-ctrl resolve hangs on Mac with all Thread based devices #6933

Closed
bluebin14 opened this issue May 18, 2021 · 1 comment · Fixed by #6938
Closed

chip-device-ctrl resolve hangs on Mac with all Thread based devices #6933

bluebin14 opened this issue May 18, 2021 · 1 comment · Fixed by #6938

Comments

@bluebin14
Copy link
Contributor

Problem

chip-device-ctrl resolve hangs on the Mac with all Thread based devices. To reproduce it:

1 - commission a BLE device to CHIP Thread network
2 - call close-ble
3 - call resolve with appropriate fabricId and nodeId parameters

Result: the call never returns, the tool must be force quit.

The explanation is:
src/platform/Darwin/MdnsImpl.cpp calls DNSServiceGetAddrInfo with 0 flags parameter which means no timeout, and kDNSServiceProtocol_IPv4 protocol parameter which restricts search to IPv4 only. In the case of Thread devices this is impossible to succeed since by definition all Thread devices are on IPv6 network.

Proposed Solution

In src/platform/Darwin/MdnsImpl.cpp call DNSServiceGetAddrInfo with combined kDNSServiceProtocol_IPv4 | kDNSServiceProtocol_IPv6 protocol parameter, then everything works.

@bluebin14
Copy link
Contributor Author

#6938

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant