kikito / love-loader

Threaded resource loading for LÖVE
http://love2d.org
MIT License
131 stars 16 forks source link

Remove reference to thread from loader after completion. #21

Closed TannerRogalsky closed 6 years ago

TannerRogalsky commented 6 years ago

We’ve signalled the loading thread to shut down but it’s possible that we have another update tick before it manages to do so. We’re already checking that loader.thread exists so removing the reference to that thread is an effective guard against a slow thread ending.

If would be better to remove the condition that creates this race in the first place but this should be an adequate stopgap.

This fixes #8.