espressif / esp-protocols

Collection of ESP-IDF components related to networking protocols
181 stars 126 forks source link

fix(mdns): free txt value len (IDFGH-12817) #569

Closed DejinChen closed 4 months ago

DejinChen commented 4 months ago

Free the new malloced txt_value_len instead of the txt_value_len in search result. If there exits txt entry in query results, the origin free processing will lead a crash due to multi free.

chshu commented 4 months ago

@gabsuren @david-cermak PTAL.

https://github.com/espressif/esp-protocols/pull/522 intended to fix a memory leak issue but introduced this issue.

Could you please help to release mdns 1.3.1 version with this fix? It's a critial bug found in both the Matter and Thread BR applications.

gabsuren commented 4 months ago

@chshu release mdns-v1.3.1 is already available https://components.espressif.com/components/espressif/mdns