diff options
Diffstat (limited to 'qapi/string-output-visitor.c')
-rw-r--r-- | qapi/string-output-visitor.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/qapi/string-output-visitor.c b/qapi/string-output-visitor.c index bdc0fd0be4..ff9ddf068a 100644 --- a/qapi/string-output-visitor.c +++ b/qapi/string-output-visitor.c @@ -322,6 +322,13 @@ static void free_range(void *range, void *dummy) g_free(range); } +static void string_output_free(Visitor *v) +{ + StringOutputVisitor *sov = to_sov(v); + + string_output_visitor_cleanup(sov); +} + void string_output_visitor_cleanup(StringOutputVisitor *sov) { if (sov->string) { @@ -351,6 +358,7 @@ StringOutputVisitor *string_output_visitor_new(bool human) v->visitor.start_list = start_list; v->visitor.next_list = next_list; v->visitor.end_list = end_list; + v->visitor.free = string_output_free; return v; } |