-
Notifications
You must be signed in to change notification settings - Fork 715
Memory leak #963
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
Comments
Hi, During investigating memory leak in BLEScan i found that leak cause was in my test code, not scan class itself. It was caused by using Task class from this repo wrong way. Maybe if you can narrow down where you have memory leak i can investigate it. |
Hi,
Hope you could help, thanks! Niek |
This will create new instance of class, but you never delete it: |
Thank you for your advice. I can delete the Hope you can give more clarity on that. |
I always lamented that piece of code, this repo has an alternative onResult method defined that I suggest you use. Change: Then change all the And change To: That should solve your memory leaks. Edit: Forgot a part. Or do as chegewara shows below. |
|
Thank you very much! I fixed the memory leak issue! |
Dear readers,
After running the BLE_client sketch for a while it crashes because of memory leak.
It is also visible with the following function
Serial.println(ESP.getFreeHeap());
.Someone having the same issue according to the memory leaks within the BLE library?
Maybe a solution to these memory leaks?
Thank you in advance.
Yours sincerely,
Niek
The text was updated successfully, but these errors were encountered: