summaryrefslogtreecommitdiff
path: root/tables/apr_tables.c
diff options
context:
space:
mode:
authorBrian Pane <brianp@apache.org>2002-07-13 07:08:41 +0000
committerBrian Pane <brianp@apache.org>2002-07-13 07:08:41 +0000
commitf7e9c4b375953a2b13e4a2f6403b1fbc7f431964 (patch)
tree96189dc3792f613a038b20e6cd3d1bbb55f417e5 /tables/apr_tables.c
parent270bf7a1d1b700186b45bb2463ccd585ac8974d3 (diff)
downloadapr-f7e9c4b375953a2b13e4a2f6403b1fbc7f431964.tar.gz
Changed apr_table_elts() and apr_is_empty_table() from macros
to functions to make apr_table_t a fully abstract type git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@63650 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'tables/apr_tables.c')
-rw-r--r--tables/apr_tables.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/tables/apr_tables.c b/tables/apr_tables.c
index 1949af9db..9f7a3bb58 100644
--- a/tables/apr_tables.c
+++ b/tables/apr_tables.c
@@ -368,6 +368,15 @@ static apr_table_entry_t *table_push(apr_table_t *t)
#define table_push(t) ((apr_table_entry_t *) apr_array_push_noclear(&(t)->a))
#endif /* MAKE_TABLE_PROFILE */
+APR_DECLARE(const apr_array_header_t *) apr_table_elts(const apr_table_t *t)
+{
+ return (const apr_array_header_t *)t;
+}
+
+APR_DECLARE(int) apr_is_empty_table(const apr_table_t *t)
+{
+ return ((t == NULL) || (t->a.nelts == 0));
+}
APR_DECLARE(apr_table_t *) apr_table_make(apr_pool_t *p, int nelts)
{