Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(mdns): Fix mdns mdns_lookup_service() to handle empty TXT
the lookup_service API calls _copy_mdns_txt_items(), which tries to allocate new TXT records, but didn't handle the case with no TXT. Originally the _copy_mdns_txt_items() called calloc() with zero's which returned NULL (on espressif toolchain), so it's safe, but we could see an error message: E (1170) mdns: Cannot allocate memory (line: 6191, free heap: 281368 bytes) This commit addresses the empty TXT case and gets rid of the error message.
- Loading branch information