From eafb02716650266f886def92dd7487b2831a96f3 Mon Sep 17 00:00:00 2001 From: Yorgos Thessalonikefs Date: Fri, 2 Oct 2026 16:01:19 +0200 Subject: [PATCH] - Document libunbound's context lifetime during an async callback. Thanks to Omar Mousa for the suggestion. --- doc/Changelog | 4 ++++ doc/libunbound.3.in | 2 ++ doc/libunbound.rst | 2 ++ 3 files changed, 8 insertions(+) diff --git a/doc/Changelog b/doc/Changelog index 7fd019da2..5e8e699d7 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -1,3 +1,7 @@ +2 October 2026: Yorgos + - Document libunbound's context lifetime during an async callback. + Thanks to Omar Mousa for the suggestion. + 28 September 2026: Wouter - Fix to log the errno for trust anchor write close fail. - Merge #1518 from nshopik: rrset: rehash copies after diff --git a/doc/libunbound.3.in b/doc/libunbound.3.in index a4fa56d38..153e2ac24 100644 --- a/doc/libunbound.3.in +++ b/doc/libunbound.3.in @@ -331,6 +331,8 @@ void my_callback_function(void* my_arg, int err, The \fBasync_id\fP is returned so you can (at your option) decide to track it and cancel the request if needed. If you pass a NULL pointer the \fBasync_id\fP is not returned. +The context, created via \fBub_ctx_create\fP, is in use during but also +after the callback and it cannot be deleted during a callback. .TP .B ub_cancel Cancel an async query in progress. diff --git a/doc/libunbound.rst b/doc/libunbound.rst index 97883dc55..1d0d44f8c 100644 --- a/doc/libunbound.rst +++ b/doc/libunbound.rst @@ -408,6 +408,8 @@ Functions The **async_id** is returned so you can (at your option) decide to track it and cancel the request if needed. If you pass a NULL pointer the **async_id** is not returned. + The context, created via **ub_ctx_create**, is in use during but also + after the callback and it cannot be deleted during a callback. ub_cancel Cancel an async query in progress.