Fix directorin SWIGTYPE typemaps to make a copy as these are used for pass by value.

Closes #434
This commit is contained in:
William S Fulton 2016-05-14 21:19:14 +01:00
commit 98a31ff633
15 changed files with 180 additions and 14 deletions

View file

@ -429,7 +429,7 @@
%typemap(directorin) SWIGTYPE
{
SWIG_SetPointerZval($input, SWIG_as_voidptr(&$1), $&1_descriptor, 2);
SWIG_SetPointerZval($input, SWIG_as_voidptr(new $1_ltype((const $1_ltype &)$1)), $&1_descriptor, 1|2);
}
%typemap(out) void "";