jorton 2004/06/22 09:18:54
Modified: test testuri.c
Log:
* test/testuri.c (testuri, test_uph, test_aup): Fix compiler warnings;
use global 'p' pool.
Revision Changes Path
1.8 +4 -15 apr-util/test/testuri.c
Index: testuri.c
===================================================================
RCS file: /home/cvs/apr-util/test/testuri.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -d -w -u -r1.7 -r1.8
--- testuri.c 22 Jun 2004 10:24:14 -0000 1.7
+++ testuri.c 22 Jun 2004 16:18:54 -0000 1.8
@@ -127,6 +127,7 @@
}
};
+#if 0
static void show_info(apr_status_t rv, apr_status_t expected, const
apr_uri_t *info)
{
if (rv != expected) {
@@ -154,16 +155,15 @@
info->dns_looked_up, info->dns_resolved);
}
}
+#endif
static void test_aup(abts_case *tc, void *data)
{
- apr_pool_t *p = (apr_pool_t *)data;
int i;
apr_status_t rv;
apr_uri_t info;
struct aup_test *t;
const char *s = NULL;
- int rc = 0;
for (i = 0; i < sizeof(aup_tests) / sizeof(aup_tests[0]); i++) {
memset(&info, 0, sizeof(info));
@@ -190,13 +190,10 @@
static void test_uph(abts_case *tc, void *data)
{
- apr_pool_t *p = (apr_pool_t *)data;
int i;
apr_status_t rv;
apr_uri_t info;
struct uph_test *t;
- const char *failed;
- int rc = 0;
for (i = 0; i < sizeof(uph_tests) / sizeof(uph_tests[0]); i++) {
memset(&info, 0, sizeof(info));
@@ -213,18 +210,10 @@
abts_suite *testuri(abts_suite *suite)
{
- apr_pool_t *pool;
-
suite = ADD_SUITE(suite);
- /* do we need to run the apr_initialize and set an atexit() here? */
-
- apr_pool_create(&pool, NULL);
-
- abts_run_test(suite, test_aup, pool);
- abts_run_test(suite, test_uph, pool);
-
- apr_pool_destroy(pool);
+ abts_run_test(suite, test_aup, NULL);
+ abts_run_test(suite, test_uph, NULL);
return suite;
}