Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Memory Leak in LogBoxModule (#45261)
Summary: To fix [The Memory Leak Issue](#45080) This change modifies the timing of view creation in the LogModule. The motivation behind this update is to address a potential memory leak issue. Previously, views were being created and held onto, which could lead to references to the Activity being retained even when they were no longer needed. By creating the view only when the show method is called and ensuring it is removed in the hide method, we can prevent these memory leaks and improve the overall memory management and stability of the LogModule. Fixes #45080 - Adjusted the timing of view creation to occur when the `show` method is called. - Ensured that the created view can be removed in the `hide` method. - This update addresses potential memory leaks by preventing the view from holding a reference to the Activity. These changes improve memory management and stability within the LogModule. Modify the timing of view creation in LogModule. The view is now created when the show method is called, and it can be removed in the hide method. This change resolves potential memory leaks caused by the view holding a reference to the Activity. ## Changelog: [ANDROID] [FIXED] - Fix LogModule to create view when show is called Pull Request resolved: #45261 Reviewed By: dmytrorykun Differential Revision: D59372962 Pulled By: cortinico fbshipit-source-id: 6693afdb279c7164ff0f68c93f8ca8a54b1c2077
- Loading branch information