]> git.proxmox.com Git - mirror_frr.git/blobdiff - lib/hash.h
*: remove the checking returned value for hash_get()
[mirror_frr.git] / lib / hash.h
index 47d951a34b2a6eb9a2525e890b243663a53116c0..91770d181348bbc39dfcaffa4d6638b4314768ad 100644 (file)
@@ -161,7 +161,7 @@ hash_create_size(unsigned int size, unsigned int (*hash_key)(const void *),
  * an element from its key, you must provide the data item itself, with the
  * portions used in the hash function set to the same values as the data item
  * to retrieve. To insert a data element, either provide the key as just
- * described and provide alloc_func as descrbied below to allocate the full
+ * described and provide alloc_func as described below to allocate the full
  * data element, or provide the full data element and pass 'hash_alloc_intern'
  * to alloc_func.
  *
@@ -235,9 +235,10 @@ extern void *hash_release(struct hash *hash, void *data);
 /*
  * Iterate over the elements in a hash table.
  *
- * It is safe to delete items passed to the iteration function from the hash
- * table during iteration. More than one item cannot be deleted during each
- * iteration. Please note that adding entries to the hash
+ * The passed in arg to the handler function is the only safe
+ * item to delete from the hash.
+ *
+ * Please note that adding entries to the hash
  * during the walk will cause undefined behavior in that some new entries
  * will be walked and some will not.  So do not do this.
  *
@@ -258,8 +259,10 @@ extern void hash_iterate(struct hash *hash,
 /*
  * Iterate over the elements in a hash table, stopping on condition.
  *
- * It is safe to delete items passed to the iteration function from the hash
- * table during iteration.  Please note that adding entries to the hash
+ * The passed in arg to the handler function is the only safe item
+ * to delete from the hash.
+ *
+ * Please note that adding entries to the hash
  * during the walk will cause undefined behavior in that some new entries
  * will be walked and some will not.  So do not do this.
  *