Module: wine Branch: master Commit: 8ead7fe797fb83974a767f09986876c3c34166ef URL: http://source.winehq.org/git/wine.git/?a=commit;h=8ead7fe797fb83974a767f0998...
Author: Rob Shearman rob@codeweavers.com Date: Mon Dec 10 13:30:36 2007 +0000
widl: Make sure to generate freeing calls for all non-simple structures with pointers and pointers to user marshalled types.
---
tools/widl/typegen.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/tools/widl/typegen.c b/tools/widl/typegen.c index e40ac79..346318f 100644 --- a/tools/widl/typegen.c +++ b/tools/widl/typegen.c @@ -2601,7 +2601,9 @@ static int needs_freeing(const attr_list_t *attrs, const type_t *t, int out) (is_user_type(t) || (is_ptr(t) && (t->ref->type == RPC_FC_IP - || is_ptr(t->ref)))) + || (is_struct(t->ref->type) && t->ref->type != RPC_FC_STRUCT) + || is_ptr(t->ref) + || is_user_type(t->ref)))) || (out && is_string_type(attrs, t)) || is_array(t); }