From 6a8d2e97f1df29c546ccf88f0f58c320dbe05fc1 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 7 Jul 2006 10:06:25 +0000 Subject: [PATCH] Fix directorout typemap git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@9201 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Lib/java/java.swg | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Lib/java/java.swg b/Lib/java/java.swg index 5bb22d830..af6f6c58a 100644 --- a/Lib/java/java.swg +++ b/Lib/java/java.swg @@ -557,12 +557,13 @@ } $1 = *argp; %} -%typemap(directorout) SWIGTYPE -%{ if (!$input) { +%typemap(directorout) SWIGTYPE ($&1_type argp) +%{ argp = *($&1_ltype*)&$input; + if (!argp) { SWIG_JavaThrowException(jenv, SWIG_JavaNullPointerException, "Unexpected null return for type $1_type"); return $null; } - $1 = *($&1_ltype)&$input; %} + $1 = *argp; %} %typemap(out) SWIGTYPE #ifdef __cplusplus