Add timeout option to block_receive() method.