Performing Message Digest Operations Based on the Context
For details, see Performing Digest Operations Based on the Context. This section only adds the tag input parameter for invoking the callback function in the poll thread after the task is complete.
1 2 3 4 5 6 7 8 9 10 11 12 | struct digest_async_tag { void *ctx; void *pool; int thread_id; int cnt; } *tag; tag = malloc(sizeof(*tag)); tag->ctx = ctx; tag->thread_id = thread_id; tag->cnt = 0; tag->pool = pool; wcrypto_do_digest(ctx, &opdata, tag); |
Parent topic: Digest Asynchronous Interface Usage Examples