HuoLanguage / huo

interpreted language written in C
MIT License
213 stars 21 forks source link

Freeing execution bundle before pthread join #4

Closed tomsmeding closed 8 years ago

tomsmeding commented 8 years ago

Forgive me for not actually testing this, but shouldn't these two lines be swapped? It appears to me that the thread might still be using the data at the point when you already free it.

Awesome work otherwise!

incrediblesound commented 8 years ago

Thank you for pointing this out! I think it definitely makes more sense to free the execution bundle after pthread join.