Fix usage of dangling pointer

Using a constref from a block that is dispatched async =
using stack memory from another thread that might be gone by the time
you have dispatched = crash
Merge pull request #5 from nevyn/master

Fix usage of dangling pointer