diff options
author | Joe Orton <jorton@apache.org> | 2008-08-06 14:29:12 +0000 |
---|---|---|
committer | Joe Orton <jorton@apache.org> | 2008-08-06 14:29:12 +0000 |
commit | a933a827982e603e9c2c56b471073ac425ba4af1 (patch) | |
tree | c6f464c5ed870f6ef7bfb87369bd0303aed6e561 /include/apr_tables.h | |
parent | 544f55179556769ad7570b983519d17382b61764 (diff) | |
download | apr-a933a827982e603e9c2c56b471073ac425ba4af1.tar.gz |
* include/apr_strings.h (apr_pstrcat): Mark with sentinel attribute
for GCC >= 4; triggers a compiler warning if the function is called
without a final NULL argument.
* include/apr_tables.h (apr_table_do): Likewise.
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@683278 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'include/apr_tables.h')
-rw-r--r-- | include/apr_tables.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/apr_tables.h b/include/apr_tables.h index c2cd74138..aef5c7ba8 100644 --- a/include/apr_tables.h +++ b/include/apr_tables.h @@ -380,7 +380,11 @@ typedef int (apr_table_do_callback_fn_t)(void *rec, const char *key, * @see apr_table_do_callback_fn_t */ APR_DECLARE_NONSTD(int) apr_table_do(apr_table_do_callback_fn_t *comp, - void *rec, const apr_table_t *t, ...); + void *rec, const apr_table_t *t, ...) +#if defined(__GNUC__) && __GNUC__ >= 4 + __attribute__((sentinel)) +#endif + ; /** * Iterate over a table running the provided function once for every |