chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b4b8796
)
hashmap: document trivial_hash_func()
author
Lennart Poettering
<lennart@poettering.net>
Tue, 7 May 2013 15:51:41 +0000
(17:51 +0200)
committer
Lennart Poettering
<lennart@poettering.net>
Tue, 7 May 2013 15:52:23 +0000
(17:52 +0200)
src/shared/hashmap.h
patch
|
blob
|
history
diff --git
a/src/shared/hashmap.h
b/src/shared/hashmap.h
index 8f6e644b25d6a816506e6f07ad9c9338c8fe091c..15b7e27585e03c58f356b16bbac52ba87212abb3 100644
(file)
--- a/
src/shared/hashmap.h
+++ b/
src/shared/hashmap.h
@@
-43,6
+43,9
@@
typedef int (*compare_func_t)(const void *a, const void *b);
unsigned string_hash_func(const void *p) _pure_;
int string_compare_func(const void *a, const void *b) _pure_;
unsigned string_hash_func(const void *p) _pure_;
int string_compare_func(const void *a, const void *b) _pure_;
+/* This will compare the passed pointers directly, and will not
+ * dereference them. This is hence not useful for strings or
+ * suchlike. */
unsigned trivial_hash_func(const void *p) _const_;
int trivial_compare_func(const void *a, const void *b) _const_;
unsigned trivial_hash_func(const void *p) _const_;
int trivial_compare_func(const void *a, const void *b) _const_;