projects
/
urcu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
doc/examples: cds_lfht_destroy
[urcu.git]
/
doc
/
examples
/
rculfhash
/
cds_lfht_add_unique.c
diff --git
a/doc/examples/rculfhash/cds_lfht_add_unique.c
b/doc/examples/rculfhash/cds_lfht_add_unique.c
index ec594c803961b8b12ff5c328a33d50192d96ede6..f1a7631d5a4cd5a35522e87754632ecfc1b65d3c 100644
(file)
--- a/
doc/examples/rculfhash/cds_lfht_add_unique.c
+++ b/
doc/examples/rculfhash/cds_lfht_add_unique.c
@@
-33,6
+33,7
@@
struct mynode {
struct cds_lfht_node node; /* Chaining in hash table */
};
struct cds_lfht_node node; /* Chaining in hash table */
};
+static
int match(struct cds_lfht_node *ht_node, const void *_key)
{
struct mynode *node =
int match(struct cds_lfht_node *ht_node, const void *_key)
{
struct mynode *node =
@@
-113,11
+114,11
@@
int main(int argc, char **argv)
* match. It did not add the new node to the
* hash table, so we can free it on the spot.
*/
* match. It did not add the new node to the
* hash table, so we can free it on the spot.
*/
- printf("Not adding duplicate
key: %d, seqnum: %d
\n",
+ printf("Not adding duplicate
(key: %d, seqnum: %d)
\n",
node->value, node->seqnum);
free(node);
} else {
node->value, node->seqnum);
free(node);
} else {
- printf("Add
key: %d, seqnum: %d
\n",
+ printf("Add
(key: %d, seqnum: %d)
\n",
node->value, node->seqnum);
}
rcu_read_unlock();
node->value, node->seqnum);
}
rcu_read_unlock();
This page took
0.023278 seconds
and
4
git commands to generate.