If a foreign callback occurs on a thread that was not created by LispWorks, then some data is kept on the Lisp side to make the foreign callback entry faster next time. This data is removed when the thread dies, but you force it to be removed sooner by calling last-callback-on-thread.