I'm developing an Mqtt client for an emdedded IoT application, and I'm using mqtt::AsyncClient.
I'm implemented my client following the guidelines of "legacy_async_subscribe.rs" in the examples of the distribution package. Everything works fine, but when the client tries to reconnect, because of a connection lost, it exit with some error. I tried with the original client in the example "legacy_async_subscribe.rs" connected to "test.mosuitto.org" and after several hours of connection I've got the following error, which resamples to the one reported in a previous converstion but is not the same:
Connection lost. Attempting reconnect.
Connection attempt failed with error code -1.
Subscribing to topics: ["UAU/test/one", "UAU/hello/one"]
legacy_async_subscribe(92357,0x16efdb000) malloc: Heap corruption detected, free list is damaged at 0x600000920020
*** Incorrect guard value: 141733920773
legacy_async_subscribe(92357,0x16efdb000) malloc: *** set a breakpoint in malloc_error_break to debug
zsh: abort cargo run --example legacy_async_subscribe -v