Hello,
function exec_set_found uses a PointerGetDatum, should be BoolGetDatum
*** pl_exec.c.orig 2011-11-24 12:51:45.000000000 +0100
--- pl_exec.c 2011-11-27 18:07:46.983118326 +0100
***************
*** 5860,5866 ****
PLpgSQL_var *var;
var = (PLpgSQL_var *) (estate->datums[estate->found_varno]);
! var->value = PointerGetDatum(state);
var->isnull = false;
}
--- 5860,5866 ----
PLpgSQL_var *var;
var = (PLpgSQL_var *) (estate->datums[estate->found_varno]);
! var->value = BoolGetDatum(state);
var->isnull = false;
}
Regards
Pavel Stehule