GNU/Weeb Mailing List <[email protected]>
 help / color / mirror / Atom feed
From: Ammar Faizi <[email protected]>
To: Jens Axboe <[email protected]>
Cc: Ammar Faizi <[email protected]>,
	Pavel Begunkov <[email protected]>,
	Alviro Iskandar Setiawan <[email protected]>,
	io-uring Mailing List <[email protected]>,
	Linux Kernel Mailing List <[email protected]>,
	GNU/Weeb Mailing List <[email protected]>
Subject: [PATCH liburing 3/3] man/io_uring_cqe_get_data.3: Fix a misleading return value
Date: Sat, 15 Apr 2023 23:59:04 +0700	[thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>

Since commit 8ecd3fd959634df8 ("Don't clear sqe->user_data as part of
command prep"), the prep functions no longer zero the user data. If the
user_data is not set, it will contain whatever previous value in it.

Therefore, the returned value when the user_data is-not-set is not
always NULL. And oh, someone once hit an issue because they assume the
return value is NULL if the user_data is not set. See the link below.

Fix the manpage, tell that the return value will be undefined.

Signed-off-by: Ammar Faizi <[email protected]>
 man/io_uring_cqe_get_data.3 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/man/io_uring_cqe_get_data.3 b/man/io_uring_cqe_get_data.3
index 4cbb32cd864e12c2..a4d2988a49d92aa8 100644
--- a/man/io_uring_cqe_get_data.3
+++ b/man/io_uring_cqe_get_data.3
@@ -46,7 +46,7 @@ or
 If the
 .I user_data
 value has been set before submitting the request, it will be returned.
-Otherwise the functions returns NULL.
+Otherwise, the return value is undefined.
 .BR io_uring_get_sqe (3),
 .BR io_uring_sqe_set_data (3),
Ammar Faizi

  parent reply	other threads:[~2023-04-15 16:59 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-15 16:59 [PATCH liburing 0/3] io_uring-udp fix, manpage fix, and hppa cross-compiler Ammar Faizi
2023-04-15 16:59 ` [PATCH liburing 1/3] io_uring-udp: Fix the wrong IPv6 binary to string conversion Ammar Faizi
2023-04-15 16:59 ` [PATCH liburing 2/3] github: Add hppa cross compiler Ammar Faizi
2023-04-15 16:59 ` Ammar Faizi [this message]
2023-04-15 20:37 ` [PATCH liburing 0/3] io_uring-udp fix, manpage fix, and hppa cross-compiler Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox