[getdns-api] getdns_return_t for destroy methods

Paul Hoffman paul.hoffman at vpnc.org
Sat Mar 8 03:33:19 MST 2014

On Mar 6, 2014, at 4:26 PM, Goyal, Neel <ngoyal at verisign.com> wrote:

> I would like to propose that we change the signatures of the destroy routines such that they return getdns_return_t.
> 	• getdns_return_t getdns_context_destroy
> 	• getdns_return_t getdns_dict_destroy
> 	• getdns_return_t getdns_list_destroy
> This would especially be useful in getdns_context_destroy since implementations may decide that destroying a context within a callback is allowed or not.  There are some fun edge cases we’ve been dealing with regarding this.  Also, it keeps the API consistent with the other methods.
> Thoughts?

The current returns (void) were a conscious decision. The group decided that that it should be a void unless there are actual useful values returned. Given that the calls always succeed, what you would put in the return other than "good"?

--Paul Hoffman

More information about the getdns-api mailing list