# dkim_set_signature_handle_free()

[back to index]

SYNOPSIS

    #include <dkim.h>
    DKIM_STAT dkim_set_signature_handle_free(
    	DKIM_LIB *libopendkim,
            void (*func)(void *closure, void *ptr));
    );

Defines a callback function to be used for deallocating local data storage to be associated with signatures.

When destroying a `DKIM_SIGINFO` handle, any user space allocated by a call to the callback set by `dkim_set_signature_handle_free()` must also be deallocated. If this callback function is defined, it will be called once for each such handle to deallocate any caller-side storage that was previously allocated.

DESCRIPTION

Called When | `dkim_set_signature_handle_free()` can be called at any time.

ARGUMENTS

Argument | Description
--- | ---
libopendkim | Library-specific handle, returned by `dkim_init()`.
func | A pointer to a function which takes a two void pointers; the first is the same as the `memclosure` passed to `dkim_verify()`, and the second is the pointer previously returned by a call to the callback set by `dkim_set_signature_handle()`. If NULL, no callback will be used.

RETURN VALUES

- DKIM_STAT_OK -- success

NOTES

- None.

Copyright (c) 2007 Sendmail, Inc. and its suppliers. All rights reserved.
Copyright (c) 2009-2011, The OpenDKIM Project. All rights reserved.
By using this file, you agree to the terms and conditions set forth in the respective licenses.