diff options
author | Maximilian Szengel <gnunet@maxsz.de> | 2012-03-27 14:22:16 +0000 |
---|---|---|
committer | Maximilian Szengel <gnunet@maxsz.de> | 2012-03-27 14:22:16 +0000 |
commit | a3825c187b4f6acb08f0e5a0b5b0590dbe8ea9c8 (patch) | |
tree | e2f54229d4bd60c4c2099f0b8a65ea1b199571cd /src/include/gnunet_container_lib.h | |
parent | 4e35ffd43c81ff4a64c6da4e519548e452552c6b (diff) | |
download | gnunet-a3825c187b4f6acb08f0e5a0b5b0590dbe8ea9c8.tar.gz gnunet-a3825c187b4f6acb08f0e5a0b5b0590dbe8ea9c8.zip |
- dfa construction
Diffstat (limited to 'src/include/gnunet_container_lib.h')
-rw-r--r-- | src/include/gnunet_container_lib.h | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/src/include/gnunet_container_lib.h b/src/include/gnunet_container_lib.h index 75443b6ae..af64daa82 100644 --- a/src/include/gnunet_container_lib.h +++ b/src/include/gnunet_container_lib.h | |||
@@ -1152,12 +1152,28 @@ GNUNET_CONTAINER_slist_clear (struct GNUNET_CONTAINER_SList *l); | |||
1152 | * @param l list | 1152 | * @param l list |
1153 | * @param buf payload buffer to find | 1153 | * @param buf payload buffer to find |
1154 | * @param len length of the payload (number of bytes in buf) | 1154 | * @param len length of the payload (number of bytes in buf) |
1155 | * | ||
1156 | * @return GNUNET_YES if found, GNUNET_NO otherwise | ||
1155 | */ | 1157 | */ |
1156 | int | 1158 | int |
1157 | GNUNET_CONTAINER_slist_contains (const struct GNUNET_CONTAINER_SList *l, | 1159 | GNUNET_CONTAINER_slist_contains (const struct GNUNET_CONTAINER_SList *l, |
1158 | const void *buf, size_t len); | 1160 | const void *buf, size_t len); |
1159 | 1161 | ||
1160 | 1162 | /** | |
1163 | * Check if a list contains a certain element using 'compare' function | ||
1164 | * | ||
1165 | * @param l list | ||
1166 | * @param buf payload buffer to find | ||
1167 | * @param len length of the payload (number of bytes in buf) | ||
1168 | * @param compare comparison function | ||
1169 | * | ||
1170 | * @return NULL if the 'buf' could not be found, pointer to the | ||
1171 | * list element, if found | ||
1172 | */ | ||
1173 | void * | ||
1174 | GNUNET_CONTAINER_slist_contains2 (const struct GNUNET_CONTAINER_SList *l, | ||
1175 | const void *buf, size_t len, | ||
1176 | int (*compare)(const void *, const size_t, const void *, const size_t)); | ||
1161 | /** | 1177 | /** |
1162 | * Count the elements of a list | 1178 | * Count the elements of a list |
1163 | * @param l list | 1179 | * @param l list |