summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorJoshua Haberman <joshua@reverberate.org>2009-12-05 19:54:38 -0800
committerJoshua Haberman <joshua@reverberate.org>2009-12-05 19:54:38 -0800
commit08b4a91204ff7174c381f887d87878d8bb1181ff (patch)
tree431f22caea40a3ccc7e78b020b5245ac9de40d21 /tools
parent651c92ab33187b34d7878ac57427bbbc062662fa (diff)
Add a test for circularly-linked descriptors.
The test currently triggers valgrind-detected memory errors.
Diffstat (limited to 'tools')
-rw-r--r--tools/upbc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/upbc.c b/tools/upbc.c
index cb41ecc..8d41abc 100644
--- a/tools/upbc.c
+++ b/tools/upbc.c
@@ -708,6 +708,7 @@ int main(int argc, char *argv[])
int symcount;
struct upb_def **defs = upb_symtab_getandref_defs(s, &symcount);
+ upb_symtab_unref(s);
write_h(defs, symcount, h_filename, cident, h_file);
write_const_h(defs, symcount, h_filename, h_const_file);
for (int i = 0; i < symcount; i++) upb_def_unref(defs[i]);
@@ -719,7 +720,6 @@ int main(int argc, char *argv[])
fclose(c_file);
}
upb_msg_unref(fds_msg);
- upb_symtab_unref(s);
upb_string_unref(descriptor);
fclose(h_file);
fclose(h_const_file);
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback