Yes, you are right; this solves the problem.
In my original example (from the other thread mentioned in the first post) I have to typecast the second parameter to void*.
Thank you for pointing this out, Larry!