diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2020-11-16 13:49:48 -0800 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2020-11-16 13:59:52 -0800 |
commit | afacc269ee1527714bb4f02c155c038c766d9a7f (patch) | |
tree | eaa3e62696a0977a608d6029663ce701198012b5 /example.c | |
parent | 71d53baee273ab397533c2585293457a620a66df (diff) |
thunk: add thunk_dispatch_keep() non-freeing variant
In scenarios where a thunk instance must be dispatched multiple
times, the automatic free is a problem.
This commit moves the free out of the dispatch implementations
and into the thunk_dispatch() wrapper. So the behavior of
thunk_dispatch() is unchanged.
The new thunk_dispatch_keep() is a plain ->dispatch(). This does
implicitly turn 'thunk_t *' being a free() able allocation into
part of the API, which may be a problem later. But who cares,
this is a .h for vendoring, not a .so w/ABI guarantees.
Diffstat (limited to 'example.c')
0 files changed, 0 insertions, 0 deletions