diff options
author | Kai Blin <kai@samba.org> | 2010-09-28 20:33:54 -0700 |
---|---|---|
committer | Kai Blin <kai@samba.org> | 2010-10-04 20:59:59 +0200 |
commit | ee7ee2c4c2f4c75c355cc06ce29d1ef59b2ae581 (patch) | |
tree | f1b10c7426fc47d9aa7dbd8777c2b84ef04a39a5 /pidl | |
parent | 013780b1e1942522dfee59d973a341b5f18ace67 (diff) | |
download | samba-ee7ee2c4c2f4c75c355cc06ce29d1ef59b2ae581.tar.gz samba-ee7ee2c4c2f4c75c355cc06ce29d1ef59b2ae581.tar.bz2 samba-ee7ee2c4c2f4c75c355cc06ce29d1ef59b2ae581.zip |
ndr: Implement push function for IPv6 addresses
Thanks to Julien Kerihuel for providing the patch that pushed me to
finish my own IPv6 patches.
Diffstat (limited to 'pidl')
-rw-r--r-- | pidl/lib/Parse/Pidl/Samba4/Python.pm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pidl/lib/Parse/Pidl/Samba4/Python.pm b/pidl/lib/Parse/Pidl/Samba4/Python.pm index b494ec9b98..3318229f0e 100644 --- a/pidl/lib/Parse/Pidl/Samba4/Python.pm +++ b/pidl/lib/Parse/Pidl/Samba4/Python.pm @@ -921,6 +921,11 @@ sub ConvertObjectFromPythonData($$$$$$;$) return; } + if ($actual_ctype->{TYPE} eq "SCALAR" and $actual_ctype->{NAME} eq "ipv6address") { + $self->pidl("$target = PyString_AsString($cvar);"); + return; + } + if ($actual_ctype->{TYPE} eq "SCALAR" and $actual_ctype->{NAME} eq "dnsp_name") { $self->pidl("$target = PyString_AS_STRING($cvar);"); return; @@ -1088,6 +1093,7 @@ sub ConvertScalarToPython($$$) # Not yet supported if ($ctypename eq "string_array") { return "PyCObject_FromTallocPtr($cvar)"; } if ($ctypename eq "ipv4address") { return "PyString_FromString_check_null($cvar)"; } + if ($ctypename eq "ipv6address") { return "PyString_FromString_check_null($cvar)"; } if ($ctypename eq "dnsp_name") { return "PyString_FromString_check_null($cvar)"; } if ($ctypename eq "pointer") { return "PyCObject_FromTallocPtr($cvar)"; |