summaryrefslogtreecommitdiff
path: root/lib/shash.c
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2009-06-24 10:21:25 -0700
committerBen Pfaff <blp@nicira.com>2009-07-06 09:07:23 -0700
commit732dcb37a81c657fa587650bbf237e5f9c2bbc0d (patch)
tree00d4c89bdf924850ad46a94b0e61e16b531275b1 /lib/shash.c
parent98742ab8656cfb4d9aa2b6fb13bf79f237814b98 (diff)
downloadopenvswitch-732dcb37a81c657fa587650bbf237e5f9c2bbc0d.tar.gz
shash: New function shash_is_empty().
Diffstat (limited to 'lib/shash.c')
-rw-r--r--lib/shash.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/shash.c b/lib/shash.c
index 9ddafe0be..7f6908436 100644
--- a/lib/shash.c
+++ b/lib/shash.c
@@ -51,6 +51,12 @@ shash_clear(struct shash *sh)
}
}
+bool
+shash_is_empty(const struct shash *shash)
+{
+ return hmap_is_empty(&shash->map);
+}
+
/* It is the caller's responsible to avoid duplicate names, if that is
* desirable. */
void