[erlang-questions] Return value of driver_async

Steve Vinoski vinoski@REDACTED
Fri Oct 17 20:56:57 CEST 2014


On Fri, Oct 17, 2014 at 2:49 PM, Steve Vinoski <vinoski@REDACTED> wrote:

>
>
> On Fri, Oct 17, 2014 at 1:58 PM, Alexey Romanov <
> alexey.v.romanov@REDACTED> wrote:
>
>> Documentation for driver_async says it returns a handle to the
>> asynchronous task. However, I can't find any other mentions of these
>> handles in erl_driver or driver_entry docs. What can/should this value be
>> used for? Or should it be ignored?
>>
>
> There was an old function driver_async_cancel() for canceling async jobs
> that took the handle as an argument, but it was deprecated a long time ago
> and it's since been removed. So, you can just ignore the handle. I'll see
> if I can patch the docs to clarify this.
>

Correction: you should check the returned handle to make sure it's not less
than zero, as negative handle values indicate that an error occurred. But
if it's not less than zero, then you can ignore it.

--steve
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20141017/8209a1ea/attachment.htm>


More information about the erlang-questions mailing list