diff options
author | Joshua Haberman <jhaberman@gmail.com> | 2019-01-16 18:50:46 -0800 |
---|---|---|
committer | Joshua Haberman <jhaberman@gmail.com> | 2019-01-16 18:50:46 -0800 |
commit | 01557462cc211cec9c7bddede77995b938067ea5 (patch) | |
tree | d06853c0af2d947a260a734c3b94089c5ddd8269 /upb/def.c | |
parent | 84fb01ad0f7301b416e03d97fbffef1a7512e7ea (diff) |
upb_symtab_add() returns upb_filedef* instead of bool.
Diffstat (limited to 'upb/def.c')
-rw-r--r-- | upb/def.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1649,9 +1649,9 @@ static bool upb_symtab_addtotabs(upb_symtab *s, symtab_addctx *ctx, return true; } -bool upb_symtab_addfile(upb_symtab *s, - const google_protobuf_FileDescriptorProto *file_proto, - upb_status *status) { +const upb_filedef *upb_symtab_addfile( + upb_symtab *s, const google_protobuf_FileDescriptorProto *file_proto, + upb_status *status) { upb_arena *tmparena = upb_arena_new(); upb_strtable addtab; upb_alloc *alloc = upb_arena_alloc(s->arena); @@ -1672,7 +1672,7 @@ bool upb_symtab_addfile(upb_symtab *s, upb_symtab_addtotabs(s, &ctx, status); upb_arena_free(tmparena); - return ok; + return ok ? file : NULL; } /* Include here since we want most of this file to be stdio-free. */ |