From d1807aa9c538e43b0567968fb6334d7e26f84cdf Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Fri, 14 Dec 2007 14:28:16 +0100 Subject: r26455: Use new talloctype macro in generated SWIG code as well. (This used to be commit 77748c6a9f118c1a2fb9dbc76546d767f1cc27eb) --- source4/pidl/lib/Parse/Pidl/Samba4/SWIG.pm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'source4/pidl/lib/Parse') diff --git a/source4/pidl/lib/Parse/Pidl/Samba4/SWIG.pm b/source4/pidl/lib/Parse/Pidl/Samba4/SWIG.pm index 29f7835949..58b52df8d3 100644 --- a/source4/pidl/lib/Parse/Pidl/Samba4/SWIG.pm +++ b/source4/pidl/lib/Parse/Pidl/Samba4/SWIG.pm @@ -60,6 +60,8 @@ sub ParseInterface($$) pidl "typedef struct $if->{NAME} { struct dcerpc_pipe *pipe; } $if->{NAME};"; pidl "}"; pidl ""; + pidl "%talloctype($if->{NAME});"; + pidl ""; pidl "\%extend $if->{NAME} {"; indent(); pidl "$if->{NAME} () {"; @@ -75,10 +77,6 @@ sub ParseInterface($$) deindent; pidl "}"; pidl ""; - pidl "~$if->{NAME}() {"; - pidl "\ttalloc_free(\$self);"; - pidl "}"; - pidl ""; foreach my $fn (@{$if->{FUNCTIONS}}) { pidl "/* $fn->{NAME} */"; @@ -158,6 +156,7 @@ sub Parse($$$$) pidl "%}"; pidl "\%import \"../rpc/dcerpc.i\""; pidl "\%import \"../../libcli/util/errors.i\""; + pidl "\%import \"../../lib/talloc/talloc.i\""; pidl ""; foreach (@$ndr) { IgnoreInterface($basename, $_) if ($_->{TYPE} eq "INTERFACE"); -- cgit