From b69812100b25bcc1df3c731fac8cc79c7b7f3537 Mon Sep 17 00:00:00 2001 From: yy214123 Date: Sun, 2 Mar 2025 22:43:41 +0800 Subject: [PATCH] Fix incorrect comments The previous comment incorrectly stated that the middle node would be returned. However, the function is a boolean function that returns true or false depending on whether the deletion was successful. This commit updates the description to clarify that the node is deleted, not returned. Change-Id: If622f30a5df04b14602b922f7dd1fb8ceabfaefd --- queue.h | 2 +- scripts/checksums | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/queue.h b/queue.h index bcd1088ee..2d9466d80 100644 --- a/queue.h +++ b/queue.h @@ -134,7 +134,7 @@ int q_size(struct list_head *head); * * The middle node of a linked list of size n is the * ⌊n / 2⌋th node from the start using 0-based indexing. - * If there're six elements, the third member should be returned. + * If there're six elements, the third member should be deleted. * * Reference: * https://leetcode.com/problems/delete-the-middle-node-of-a-linked-list/ diff --git a/scripts/checksums b/scripts/checksums index 31710faa7..87ff044d7 100644 --- a/scripts/checksums +++ b/scripts/checksums @@ -1,3 +1,3 @@ -45da6585400a15237f09d896bbb807f85f449e92 queue.h +398b59c23f699ff1bf1e73a94503a9a91caa9207 queue.h 9be9666430f392924f5d27caa71a412527bf9267 list.h 3bb0192cee08d165fd597a9f6fbb404533e28fcf scripts/check-commitlog.sh