Use a deadline from the calling process

Closes #21.