lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Tue, 5 May 2009 14:32:40 +0200 (CEST)
From:	Jiri Kosina <jkosina@...e.cz>
To:	"figo.zhang" <figo.zhang@...orific.com>
Cc:	rdunlap@...otime.net, Andrew Morton <akpm@...ux-foundation.org>,
	Andrea Arcangeli <aarcange@...hat.com>,
	linux-kernel@...r.kernel.org, David Woodhouse <dwmw2@...radead.org>
Subject: Re: [PATCH][RESEND]Documentation/rbtree.txt: cleanup kerneldoc of
 rbtree.txt

On Fri, 17 Apr 2009, figo.zhang wrote:

>  The first formal parameter of the rb_link_node() is a pointer, and the
>  "node" is define a data struct (pls see line 67 and line 73 in the
>  doc), so the actual parameter should use "&data->node".
> 
> Signed-off-by: Figo.zhang <figo.zhang@...orific.com>
> ---
>  Documentation/rbtree.txt |    8 ++++----
>  1 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/Documentation/rbtree.txt b/Documentation/rbtree.txt
> index 7224459..7710214 100644
> --- a/Documentation/rbtree.txt
> +++ b/Documentation/rbtree.txt
> @@ -131,8 +131,8 @@ Example:
>    	}
>  
>    	/* Add new node and rebalance tree. */
> -  	rb_link_node(data->node, parent, new);
> -  	rb_insert_color(data->node, root);
> +  	rb_link_node(&data->node, parent, new);
> +  	rb_insert_color(&data->node, root);
>  
>  	return TRUE;
>    }
> @@ -146,10 +146,10 @@ To remove an existing node from a tree, call:
>  
>  Example:
>  
> -  struct mytype *data = mysearch(mytree, "walrus");
> +  struct mytype *data = mysearch(&mytree, "walrus");
>  
>    if (data) {
> -  	rb_erase(data->node, mytree);
> +  	rb_erase(&data->node, &mytree);
>    	myfree(data);
>    }
>  

Didn't find it in today's linux-next pileup, so I have applied it to 
trivial tree. Thanks,

-- 
Jiri Kosina
SUSE Labs
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ