Skip to content
This repository has been archived by the owner on Jul 23, 2019. It is now read-only.

iOS: Tools retain SketchView causing memory leaks #35

Open
jeremywiebe opened this issue Aug 22, 2018 · 0 comments
Open

iOS: Tools retain SketchView causing memory leaks #35

jeremywiebe opened this issue Aug 22, 2018 · 0 comments

Comments

@jeremywiebe
Copy link

I was working through a memory leak bug in our React Native app today and I tracked it down to this library. I haven't fully diagnosed the problem, but it looks like there is a circular reference between the tools and the sketch view.

I'm working on fixing this and will be submitting one, or more, PRs to fix this reference cycle.

Here's a view of the leak profiler while running the app. Notice the stair stepping as I navigate into and back out of the view that contains the <SketchView />:

screen shot 2018-08-22 at 12 24 03 pm

Next I did the same thing and used the Visual Memory Debugger. It showed the retain cycle between the SketchView and various tools.

screen shot 2018-08-22 at 12 22 29 pm

@jeremywiebe jeremywiebe changed the title [Memory Leak] Tools retain SketchView causing memory leaks [iOS] Tools retain SketchView causing memory leaks Aug 22, 2018
@jeremywiebe jeremywiebe changed the title [iOS] Tools retain SketchView causing memory leaks iOS: Tools retain SketchView causing memory leaks Aug 22, 2018
@jeremywiebe jeremywiebe reopened this Aug 22, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant