thread: work on accessing the context.
Related to issue #7.