diff options
author | Joshua Haberman <jhaberman@gmail.com> | 2011-05-10 21:59:46 -0700 |
---|---|---|
committer | Joshua Haberman <jhaberman@gmail.com> | 2011-05-10 21:59:46 -0700 |
commit | 3231fd0fdd64bc6355bce921a988713524726f23 (patch) | |
tree | 326d6c6d334d14005db80c448fca485f641ed516 /src/upb_textprinter.c | |
parent | ea2a80840e08887e6e5ea59bce1f56a3c69bd38c (diff) |
Vastly improved/simplified the upb_handlers API.
Diffstat (limited to 'src/upb_textprinter.c')
-rw-r--r-- | src/upb_textprinter.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/upb_textprinter.c b/src/upb_textprinter.c index 2f3a6b5..7d0a9dd 100644 --- a/src/upb_textprinter.c +++ b/src/upb_textprinter.c @@ -185,12 +185,13 @@ void upb_textprinter_reset(upb_textprinter *p, upb_bytesink *sink, p->indent_depth = 0; } -void upb_textprinter_reghandlers(upb_handlers *h) { - upb_register_all(h, +upb_mhandlers *upb_textprinter_reghandlers(upb_handlers *h, upb_msgdef *m) { + upb_handlerset hset = { NULL, // startmsg NULL, // endmsg upb_textprinter_value, upb_textprinter_startsubmsg, upb_textprinter_endsubmsg - ); + }; + return upb_handlers_reghandlerset(h, m, &hset); } |