From 18291eedc3cb6bf4386698620ad9d02ad367126a Mon Sep 17 00:00:00 2001 From: Joshua Haberman Date: Sat, 5 Dec 2009 10:32:53 -0800 Subject: Make defs refcounted, rename upb_context->upbsymtab. There is currently a memory leak when type definitions form cycles. This will need to be dealt with. --- tests/tests.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'tests/tests.c') diff --git a/tests/tests.c b/tests/tests.c index ddf6d6f..9fbfa3a 100644 --- a/tests/tests.c +++ b/tests/tests.c @@ -4,7 +4,7 @@ #include #include #include "upb_parse.c" -#include "upb_context.h" +#include "upb_def.h" int num_assertions = 0; #define ASSERT(expr) do { \ @@ -227,10 +227,10 @@ static void test_get_f_uint32_t() #undef TEST } -static void test_upb_context() { - struct upb_context *c = upb_context_new(); +static void test_upb_symtab() { + struct upb_symtab *c = upb_symtab_new(); ASSERT(c); - upb_context_unref(c); + upb_symtab_unref(c); } @@ -247,7 +247,7 @@ int main() TEST(test_get_v_uint32_t); TEST(test_skip_v_uint64_t); TEST(test_get_f_uint32_t); - TEST(test_upb_context); + TEST(test_upb_symtab); printf("All tests passed (%d assertions).\n", num_assertions); return 0; } -- cgit v1.2.3